From Nico Kruithof, "Attached is a patch that makes the spherical manipulator frame rate independent. This is similar to what Lee did for the trackball manipulator a couple of months ago."
This commit is contained in:
@@ -143,6 +143,17 @@ class OSGGA_EXPORT SphericalManipulator : public MatrixManipulator
|
||||
bool _thrown;
|
||||
bool _allowThrow;
|
||||
|
||||
/** The approximate amount of time it is currently taking to draw a frame.
|
||||
* This is used to compute the delta in translation/rotation during a thrown display update.
|
||||
* It allows us to match an delta in position/rotation independent of the rendering frame rate.
|
||||
*/
|
||||
double _delta_frame_time;
|
||||
|
||||
/** The time the last frame started.
|
||||
* Used when _rate_sensitive is true so that we can match display update rate to rotation/translation rate.
|
||||
*/
|
||||
double _last_frame_time;
|
||||
|
||||
RotationMode _rotationMode;
|
||||
osg::Vec3d _center;
|
||||
double _distance;
|
||||
|
||||
Reference in New Issue
Block a user