magnum-examples
magnum-examples copied to clipboard
Update ArcBallCamera.h
Change the frustum clip distance. The current 'far' clip is too small, thus some large objects can be cut off.
Hmm, this could cause depth precision issues on certain browsers / platforms which use a 16-bit depth buffer by default. I'm not sure what's the situation right now but not so long ago Firefox suffered quite a lot from this (see https://github.com/mosra/magnum-examples/issues/34, https://bugzilla.mozilla.org/show_bug.cgi?id=1202387).
Maybe a better option would be to make this configurable from outside? So you extend it where needed and leave in safe bounds where the default is enough.
Sure. I changed that. Now the near/far parameters are optional. This is the prerequisite for my next example.