Example #1
0
 // ---------------------------------
 static private void MouseEndTrackBall(int x, int y)
 {
     // y = camera.viewHeight - y;
     if (gTrackball)
     { // if we are currently tracking, end trackball
         if (gTrackBallRotation[0] != 0.0)
         {
             TrackBall.addToRotationTrackball(gTrackBallRotation, view.worldRotation);
         }
         gTrackBallRotation[0] = gTrackBallRotation[1] = gTrackBallRotation[2] = gTrackBallRotation[3] = 0.0f;
     }
 }
Example #2
0
 // ---------------------------------
 static public void mouseUp()
 {
     if (gDolly)
     { // end dolly
         gDolly = false;
     }
     else if (gPan)
     { // end pan
         gPan = false;
     }
     else if (gTrackball)
     { // end trackball
         gTrackball = false;
         if (gTrackBallRotation[0] != 0.0)
         {
             TrackBall.addToRotationTrackball(gTrackBallRotation, view.worldRotation);
         }
         gTrackBallRotation[0] = gTrackBallRotation[1] = gTrackBallRotation[2] = gTrackBallRotation[3] = 0.0f;
     }
 }