Skip to content

Commit

Permalink
Upon breaking a tether, reset the rotation matrices to a valid state
Browse files Browse the repository at this point in the history
  • Loading branch information
gwaldron committed Nov 20, 2023
1 parent 5eb3757 commit 7917214
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/osgEarth/EarthManipulator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1308,9 +1308,13 @@ EarthManipulator::clearViewpoint()
_setVP0.unset();
_setVP1.unset();

if (breakingTether)
{
collapseTetherRotationIntoRotation();
}

// Restore the matrix values in a neutral state.
recalculateCenterFromLookVector();
//resetLookAt();

// Fire the callback to indicate a tethering break.
if ( _tetherCallback.valid() && breakingTether )
Expand Down

0 comments on commit 7917214

Please sign in to comment.