Rendering/vtkInteractorStyleImage.h Source File

Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages

# Rendering/vtkInteractorStyleImage.h

Go to the documentation of this file.

    00001 /*=========================================================================
    00002
    00003   Program:   Visualization Toolkit
    00004   Module:    $RCSfile: vtkInteractorStyleImage.h,v $
    00005   Language:  C++
    00006
    00007   Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen
    00008   All rights reserved.
    00009   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
    00010
    00011      This software is distributed WITHOUT ANY WARRANTY; without even
    00012      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
    00013      PURPOSE.  See the above copyright notice for more information.
    00014
    00015 =========================================================================*/
    00062 #ifndef __vtkInteractorStyleImage_h
    00063 #define __vtkInteractorStyleImage_h
    00064
    00065 #include "vtkInteractorStyleTrackballCamera.h"
    00066
    00067 // Motion flags
    00068
    00069 #define VTKIS_WINDOW_LEVEL 1024
    00070 #define VTKIS_PICK         1025
    00071
    00072 class VTK_RENDERING_EXPORT vtkInteractorStyleImage : public vtkInteractorStyleTrackballCamera
    00073 {
    00074 public:
    00075   static vtkInteractorStyleImage *New();
    00076   vtkTypeRevisionMacro(vtkInteractorStyleImage, vtkInteractorStyleTrackballCamera);
    00077   void PrintSelf(ostream& os, vtkIndent indent);
    00078
    00080
    00081   vtkGetVector2Macro(WindowLevelStartPosition,int);
    00082   vtkGetVector2Macro(WindowLevelCurrentPosition,int);
    00084
    00086
    00088   virtual void OnMouseMove();
    00089   virtual void OnLeftButtonDown();
    00090   virtual void OnLeftButtonUp();
    00091   virtual void OnRightButtonDown();
    00092   virtual void OnRightButtonUp();
    00094
    00096   virtual void OnChar();
    00097
    00098   // These methods for the different interactions in different modes
    00099   // are overridden in subclasses to perform the correct motion. Since
    00100   // they might be called from OnTimer, they do not have mouse coord parameters
    00101   // (use interactor's GetEventPosition and GetLastEventPosition)
    00102   virtual void WindowLevel();
    00103   virtual void Pick();
    00104
    00105   // Interaction mode entry points used internally.
    00106   virtual void StartWindowLevel();
    00107   virtual void EndWindowLevel();
    00108   virtual void StartPick();
    00109   virtual void EndPick();
    00110
    00111 protected:
    00112   vtkInteractorStyleImage();
    00113   ~vtkInteractorStyleImage();
    00114
    00115   int WindowLevelStartPosition[2];
    00116   int WindowLevelCurrentPosition[2];
    00117
    00118 private:
    00119   vtkInteractorStyleImage(const vtkInteractorStyleImage&);  // Not implemented.
    00120   void operator=(const vtkInteractorStyleImage&);  // Not implemented.
    00121 };
    00122
    00123 #endif