]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Fix for PAL14011 : Strange behaviour in rotation in VTK Viewer.
authormkr <mkr@opencascade.com>
Mon, 27 Nov 2006 13:53:29 +0000 (13:53 +0000)
committermkr <mkr@opencascade.com>
Mon, 27 Nov 2006 13:53:29 +0000 (13:53 +0000)
src/SVTK/SVTK_InteractorStyle.cxx

index 9959ea2ff10ebd2a929682f9161189c54bdb72ea..de0dbbb740756c95b862a9171710298753e9a885 100644 (file)
@@ -282,13 +282,16 @@ SVTK_InteractorStyle
   
   double rxf = double(dx) * aDeltaAzimuth * this->MotionFactor;
   aTransform->RotateWXYZ(rxf, cam->GetViewUp());
-            
+
   // Elevation transformation
   double aDeltaElevation = -20.0 / size[1];
 
   double ryf = double(dy) * aDeltaElevation * this->MotionFactor;
   vtkMatrix4x4* aMatrix = cam->GetViewTransformMatrix();
-  const double anAxis[3] = {aMatrix->GetElement(0,0), aMatrix->GetElement(0,1), aMatrix->GetElement(0,2)};
+  const double anAxis[3] = {-aMatrix->GetElement(0,0), // mkr : 27.11.2006 : PAL14011 - Strange behaviour in rotation in VTK Viewer.
+                           -aMatrix->GetElement(0,1), 
+                           -aMatrix->GetElement(0,2)};
+  
   aTransform->RotateWXYZ(ryf, anAxis);
             
   aTransform->Translate(-myRotationPointX, -myRotationPointY, -myRotationPointZ);