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:
parent
e309dfd234
commit
b246580c63
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user