Main Page | Directories | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

vtkInteractorStyleTrackballCamera.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkInteractorStyleTrackballCamera.h,v $
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00051 #ifndef __vtkInteractorStyleTrackballCamera_h
00052 #define __vtkInteractorStyleTrackballCamera_h
00053 
00054 #include "vtkInteractorStyle.h"
00055 
00056 class VTK_RENDERING_EXPORT vtkInteractorStyleTrackballCamera : public vtkInteractorStyle
00057 {
00058 public:
00059   static vtkInteractorStyleTrackballCamera *New();
00060   vtkTypeRevisionMacro(vtkInteractorStyleTrackballCamera,vtkInteractorStyle);
00061   void PrintSelf(ostream& os, vtkIndent indent);
00062 
00064 
00066   virtual void OnMouseMove();
00067   virtual void OnLeftButtonDown();
00068   virtual void OnLeftButtonUp();
00069   virtual void OnMiddleButtonDown();
00070   virtual void OnMiddleButtonUp();
00071   virtual void OnRightButtonDown();
00072   virtual void OnRightButtonUp();
00073   virtual void OnMouseWheelForward();
00074   virtual void OnMouseWheelBackward();
00076 
00077   // These methods for the different interactions in different modes
00078   // are overridden in subclasses to perform the correct motion. Since
00079   // they are called by OnTimer, they do not have mouse coord parameters
00080   // (use interactor's GetEventPosition and GetLastEventPosition)
00081   virtual void Rotate();
00082   virtual void Spin();
00083   virtual void Pan();
00084   virtual void Dolly();
00085   
00086 protected:
00087   vtkInteractorStyleTrackballCamera();
00088   ~vtkInteractorStyleTrackballCamera();
00089 
00090   double MotionFactor;
00091 
00092   virtual void Dolly(double factor);
00093 
00094 private:
00095   vtkInteractorStyleTrackballCamera(const vtkInteractorStyleTrackballCamera&);  // Not implemented.
00096   void operator=(const vtkInteractorStyleTrackballCamera&);  // Not implemented.
00097 };
00098 
00099 #endif