VTK
vtkResliceImageViewer.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkResliceImageViewer.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
35 #ifndef vtkResliceImageViewer_h
36 #define vtkResliceImageViewer_h
37 
38 #include "vtkInteractionImageModule.h" // For export macro
39 #include "vtkImageViewer2.h"
40 
42 class vtkResliceCursor;
43 class vtkScalarsToColors;
46 class vtkResliceImageViewerScrollCallback;
47 class vtkPlane;
48 
50 {
51 public:
52 
54 
55  static vtkResliceImageViewer *New();
57  void PrintSelf(ostream& os, vtkIndent indent);
59 
61  virtual void Render();
62 
64 
65  virtual void SetInputData(vtkImageData *in);
66  virtual void SetInputConnection(vtkAlgorithmOutput* input);
68 
70 
71  virtual void SetColorWindow(double s);
72  virtual void SetColorLevel(double s);
74 
76 
78  vtkGetObjectMacro(ResliceCursorWidget,vtkResliceCursorWidget);
80 
82 
83  enum
84  {
85  RESLICE_AXIS_ALIGNED = 0,
86  RESLICE_OBLIQUE = 1
87  };
88  //ETX
90 
91  vtkGetMacro(ResliceMode, int);
92  virtual void SetResliceMode(int resliceMode);
94  { this->SetResliceMode(vtkResliceImageViewer::RESLICE_AXIS_ALIGNED); };
95  virtual void SetResliceModeToOblique()
96  { this->SetResliceMode(vtkResliceImageViewer::RESLICE_OBLIQUE); };
97 
99 
100  vtkResliceCursor * GetResliceCursor();
101  void SetResliceCursor( vtkResliceCursor * rc );
103 
105 
106  virtual void SetLookupTable( vtkScalarsToColors * );
107  vtkScalarsToColors * GetLookupTable();
109 
111 
112  virtual void SetThickMode( int );
113  virtual int GetThickMode();
115 
117  virtual void Reset();
118 
120 
121  vtkGetObjectMacro( PointPlacer, vtkBoundedPlanePointPlacer );
123 
125 
126  vtkGetObjectMacro( Measurements, vtkResliceImageViewerMeasurements );
128 
130 
131  vtkGetObjectMacro( Interactor, vtkRenderWindowInteractor );
133 
135 
139  vtkSetMacro( SliceScrollOnMouseWheel, int );
140  vtkGetMacro( SliceScrollOnMouseWheel, int );
141  vtkBooleanMacro( SliceScrollOnMouseWheel, int );
143 
145  virtual void IncrementSlice( int n );
146 
147  enum { SliceChangedEvent = 1001 };
148 
149 protected:
152 
153  virtual void InstallPipeline();
154  virtual void UnInstallPipeline();
155  virtual void UpdateOrientation();
156  virtual void UpdateDisplayExtent();
157  virtual void UpdatePointPlacer();
158 
160 
162  vtkPlane * GetReslicePlane();
163  double GetInterSliceSpacingInResliceMode();
165 
171  vtkResliceImageViewerScrollCallback * ScrollCallback;
172 
173 private:
174  vtkResliceImageViewer(const vtkResliceImageViewer&); // Not implemented.
175  void operator=(const vtkResliceImageViewer&); // Not implemented.
176 };
177 
178 #endif
vtkBoundedPlanePointPlacer * PointPlacer
vtkResliceCursorWidget * ResliceCursorWidget
Display a 2D image.
virtual void SetResliceModeToOblique()
virtual void SetColorLevel(double s)
virtual void Render(void)
virtual void SetInputData(vtkImageData *in)
represent a reslice cursor
Proxy object to connect input/output ports.
virtual void SetColorWindow(double s)
a placer that constrains a handle to a finite plane
Superclass for mapping scalar values to colors.
platform-independent render window interaction including picking and frame rate control.
Manage measurements on a resliced image.
virtual void InstallPipeline()
vtkResliceImageViewerMeasurements * Measurements
#define VTKINTERACTIONIMAGE_EXPORT
a simple class to control print indentation
Definition: vtkIndent.h:38
topologically and geometrically regular array of data
Definition: vtkImageData.h:44
perform various plane computations
Definition: vtkPlane.h:36
virtual void UpdateOrientation()
virtual void SetInputConnection(vtkAlgorithmOutput *input)
vtkResliceImageViewerScrollCallback * ScrollCallback
virtual void UnInstallPipeline()
static vtkImageViewer2 * New()
virtual void UpdateDisplayExtent()
Display an image along with a reslice cursor.
void PrintSelf(ostream &os, vtkIndent indent)
virtual void SetResliceModeToAxisAligned()
Geometry for a reslice cursor.