Fixed numerical accuracy problem in Trackball manipulator.
This commit is contained in:
@@ -49,6 +49,10 @@ class OSGGA_EXPORT TrackballManipulator : public CameraManipulator
|
||||
/** For the give mouse movement calculate the movement of the camera.
|
||||
Return true is camera has moved and a redraw is required.*/
|
||||
bool calcMovement();
|
||||
|
||||
void computeLocalDataFromCamera();
|
||||
|
||||
void computeCameraFromLocalData();
|
||||
|
||||
void trackball(osg::Vec3& axis,float& angle, float p1x, float p1y, float p2x, float p2y);
|
||||
float tb_project_to_sphere(float r, float x, float y);
|
||||
@@ -68,6 +72,10 @@ class OSGGA_EXPORT TrackballManipulator : public CameraManipulator
|
||||
float _minimumZoomScale;
|
||||
|
||||
bool _thrown;
|
||||
|
||||
osg::Vec3 _center;
|
||||
osg::Quat _rotation;
|
||||
float _distance;
|
||||
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user