Hi, <br><br>I&#39;m using vtkImageViewer for a 2D medical image viewer and I want to put flipping functionality. My purpose is to flip, either horizontally or verticaly, the image in axial, sagital or coronal view. I know about vtkImageFlip filter but I want to avoid it because I think I can do the same, manipulating directly the camera and it would be faster.
<br><br>My question is that I don&#39;t know exactly which is the proper method to achieve the flipping with vtkCamera. For rotations on the image I used the SetRoll method, it seems I&#39;ll need one of this ones Yaw, Azimuth, Elevation, Pitch, etc to flip, but I don&#39;t obtain the results that i like.
<br>If I&#39;m on the axial view, Yaw(180) is ok for horizontal flip, but with sagital or coronal view it doesn&#39;t behave well.<br><br>Did someone achieved correct flippings manipulating vtkCamera?<br><br>Her are some code snippets that tell what I&#39;m doing in each situation:
<br><br>To change to axial view<br><br>m_imageViewer-&gt;SetSliceOrientationToXY();<br>// this is because the vtk default axial orientation is not as the medical axial orientation<br>camera-&gt;SetFocalPoint(0,0,0);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<br>camera-&gt;SetViewUp(0,-1,0);<br>camera-&gt;SetPosition(0,0,-1);<br>renderer-&gt;ResetCamera();<br>cam-&gt;SetRoll( -m_rotateFactor*90. + 180. ); // apply the rotation of the camera, it will be always 0,90,180 or 270 degrees
<br><br><br>To change to sagital view<br>
<br>
m_imageViewer-&gt;SetSliceOrientationToYZ();<br>camera-&gt;SetRoll( -m_rotateFactor*90. -90. );<br><br><br>
To change to coronal view<br>

<br>

m_imageViewer-&gt;SetSliceOrientationToYZ();<br>
camera-&gt;SetRoll( -m_rotateFactor*90.&nbsp; );<br><br>When i update the camera to apply a flip:<br><br>if( m_applyFlip )<br>{&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; camera-&gt;OrthogonalizeViewUp();<br>&nbsp;&nbsp;&nbsp; camera-&gt;Yaw(180);<br>&nbsp;&nbsp;&nbsp; renderer()-&gt;ResetCamera();
<br>}<br>