1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-07 12:54:00 +00:00

Fix orbit camera axis

This commit is contained in:
Miloslav Číž 2017-12-13 20:08:38 +01:00
parent e309dfd234
commit b246580c63

View File

@ -697,11 +697,7 @@ namespace CSVRender
osg::Vec3d absoluteUp = osg::Vec3(0,0,1);
osg::Vec3d forward = center - eye;
osg::Vec3d axis = absoluteUp ^ forward;
if (mConstRoll && up.z() < 0.0)
axis *= -1.0;
osg::Vec3d axis = up ^ forward;
osg::Quat rotation = osg::Quat(value,axis);
osg::Vec3d oldOffset = eye - mCenter;