GOFIGURE2  0.9.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
vtkViewImage2D Class Reference

Basic class to handle 2D/3D items such as images and polydatas visualization in 2D. More...

#include <Code/ExternalCode/MegaVTK/vtkRenderingAddOn/vtkViewImage2D.h>

Inheritance diagram for vtkViewImage2D:
Inheritance graph
[legend]
Collaboration diagram for vtkViewImage2D:
Collaboration graph
[legend]

Public Types

enum  { VIEW_ORIENTATION_SAGITTAL = 0, VIEW_ORIENTATION_CORONAL = 1, VIEW_ORIENTATION_AXIAL = 2 }
 The orientation of the view is a abstract representation of the object we are looking at. It results from the acquisition plane. Setting the View Orientation by calling SetViewOrientation() will imply the view to set its inner "slice" orientation. (slice orientation == 2 means plane of acquisition.) More...
 
enum  { VIEW_CONVENTION_RADIOLOGICAL = 0, VIEW_CONVENTION_NEUROLOGICAL = 1 }
 
enum  { INTERACTOR_STYLE_NAVIGATION = 0, INTERACTOR_STYLE_RUBBER_ZOOM }
 
enum  ORIENTATION { XY = 0, XZ = 1, YZ = 2 }
 

Public Member Functions

template<class TContourContainer , class TPropertyContainer >
void AddContours (TContourContainer &iContours, TPropertyContainer &iProperty, const bool &iIntersection=true)
 Add contours with specific properties to the view. More...
 
virtual vtkActor * AddDataSet (vtkPolyData *polydata, vtkProperty *property=NULL, const bool &intersection=true, const bool &iDataVisibility=false)
 Add a dataset to the view (has to be subclass of vtkPointSet). The dataset will be cut through the implicit slice plane (GetImplicitSlicePlane()). This results in a loss of dimensionality, i.e. tetrahedron will be displayed as triangles, triangles as lines, lines as points. A vtkProperty of the dataset can be specified. More...
 
std::map< double, vtkActor * > ExtractActors (vtkPolyData *iDataSet, ORIENTATION iOrientation)
 
void GetCameraFocalAndPosition (double focal[3], double pos[3])
 Set camera focal point and position. More...
 
virtual int GetInterpolate ()
 Get whether or not the interpolation between pixels should be activated. It is Off by default. More...
 
virtual int GetSliceForWorldCoordinates (double pos[3])
 Convert a world coordinate point into an image indices coordinate point. More...
 
virtual double * GetWorldCoordinatesForSlice (int slice)
 Convert an indices coordinate point (image coordinates) into a world coordinate point. More...
 
virtual double * GetWorldCoordinatesFromDisplayPosition (int xy[2])
 Useful method that transform a display position into a world corrdinate point. More...
 
virtual double * GetWorldCoordinatesFromDisplayPosition (const int &x, const int &y)
 
virtual void Reset (void)
 Reset position - zoom - window/level to default. More...
 
virtual void ResetCamera (void)
 Reset the camera in a nice way for the 2D view. More...
 
virtual void ResetPosition (void)
 Reset the 3D position to center. More...
 
void SetCameraFocalAndPosition (double focal[3], double pos[3])
 Set camera focal point and position. More...
 
void SetDefaultInteractionStyle (void)
 Set interaction style to Default mode: Left button: Window level Right button: Zoom Middle button: Pan Wheel: Throught volume. More...
 
virtual void SetInterpolate (const int &val)
 Set whether or not the interpolation between pixels should be activated. It is Off by default. More...
 
virtual void SetOrientationMatrix (vtkMatrix4x4 *matrix)
 
void SetPanInteractionStyle (void)
 Set interaction style to Pan mode: All buttons: Pan. More...
 
void SetPickInteractionStyle (void)
 Set interaction style to Zoom mode: The actor the mouse is highlighted in addition to the Default Mode. More...
 
virtual void SetShowAnnotations (const int &iShowAnnotations)
 Set the annotation visibility. More...
 
virtual void SetSlice (int s)
 Set/Get the current slice to display (depending on the orientation this can be in X, Y or Z). More...
 
virtual void SetViewConvention (int convention)
 
virtual void SetViewOrientation (int orientation)
 
virtual void SetWorldCoordinates (double pos[3])
 The world is not always what we think it is ... Use this method to move the viewer slice such that the position (in world coordinates) given by the arguments is contained by the slice plane. If the given position is outside the bounds of the image, then the slice will be as close as possible. More...
 
void SetZoomInteractionStyle (void)
 Set interaction style to Zoom mode: All buttons: Zoom. More...
 
void SynchronizeViews (bool iSynchronize)
 
virtual void Update (void)
 Update the orientation. More...
 
 vtkBooleanMacro (Interpolate, int)
 
 vtkBooleanMacro (ShowAnnotations, int)
 Show/Hide the annotations. More...
 
 vtkGetMacro (ViewOrientation, int)
 Get the view orientation. More...
 
 vtkGetMacro (ViewConvention, int)
 Get the view orientation. More...
 
 vtkGetMacro (Zoom, double)
 Get the zoom factor in the views. More...
 
 vtkGetMacro (ShowAnnotations, int)
 Get the annotation visibility. More...
 
 vtkGetObjectMacro (SlicePlane, vtkPolyData)
 Get the polydata representing the Slice Plane. More...
 
 vtkGetObjectMacro (OrientationAnnotation, vtkOrientationAnnotation)
 Get the orientation annotation. This annotation describes the orientation of the slice plane, according to the rule Right(R)-Left(L) Anterior(A)-Posterior(P) Inferior(I)-Superior(S) More...
 
 vtkGetObjectMacro (Command, vtkViewImage2DCommand)
 
 vtkGetObjectMacro (Cursor, vtkPointHandleRepresentation2D)
 
 vtkGetObjectMacro (CursorGenerator, vtkCursor2D)
 
 vtkGetVector3Macro (CameraMotionVector, double)
 Get the camera motion vector. More...
 
 vtkGetVector3Macro (ViewCenter, double)
 Get the view center. More...
 
 vtkSetMacro (Zoom, double)
 Set the zoom factor in the views. More...
 
 vtkSetVector3Macro (CameraMotionVector, double)
 Set the camera motion vector. More...
 
 vtkTypeRevisionMacro (vtkViewImage2D, vtkViewImage)
 
- Public Member Functions inherited from vtkViewImage
virtual void Disable (void)
 Enable or Disable interaction on the view. More...
 
virtual void Enable (void)
 Enable or Disable interaction on the view. More...
 
virtual double * GetBackground (void)
 
double * GetCameraFocalPoint (void)
 Get the camera focal point. More...
 
double GetCameraParallelScale (void)
 Get the camera parallel scale. More...
 
double * GetCameraPosition (void)
 Get the camera position. More...
 
double * GetCameraViewUp (void)
 Get the camera view up. More...
 
double * GetCurrentPoint (void)
 Get the current position in world coordinate. More...
 
void GetCurrentPoint (double point[3])
 Get the current position in world coordinate. More...
 
virtual bool GetEnabled (void)
 Enable or Disable interaction on the view. More...
 
virtual int * GetImageCoordinatesFromWorldCoordinates (double position[3])
 Convert a world coordinate point into an image indices coordinate point. More...
 
virtual vtkRenderWindowInteractor * GetInteractor ()
 
double GetLevel ()
 
virtual vtkRenderWindowInteractor * GetRenderWindowInteractor ()
 
virtual double GetValueAtPosition (double worldcoordinates[3], int component=0)
 Get the pixel value at a given world coordinate point in space, return zero if out of bounds. More...
 
double GetWindow ()
 
virtual double * GetWorldCoordinatesFromImageCoordinates (int indices[3])
 Convert an indices coordinate point (image coordinates) into a world coordinate point. More...
 
virtual void Render (void)
 
virtual void ResetWindowLevel (void)
 Reset the window level. More...
 
virtual void SetBackground (double rgb[3])
 Set the background color. Format is RGB, 0 <= R,G,B <=1 Example: SetBackground(0.9,0.9,0.9) for grey-white. More...
 
virtual void SetBackground (const double &r, const double &g, const double &b)
 
void SetCameraFocalPoint (double *arg)
 Set the camera focal point. More...
 
void SetCameraParallelScale (double arg)
 Set the camera parallel scale. More...
 
void SetCameraPosition (double *arg)
 Set the camera position. More...
 
void SetCameraViewUp (double *arg)
 Set the camera view up. More...
 
virtual void SetColorLevel (double s)
 
virtual void SetColorWindow (double s)
 Set window and level for mapping pixels to colors. More...
 
virtual void SetInput (vtkImageData *input)
 
void SetLevel (double iLevel)
 
virtual void SetLookupTable (vtkLookupTable *lookuptable)
 
virtual void SetShowScalarBar (const bool &)
 Show/Hide scalar bar. More...
 
virtual void SetTextProperty (vtkTextProperty *textproperty)
 
void SetWindow (double iWindow)
 
void SetWorldCoordinates (const double &x, const double &y, const double &z)
 Set the world coordinates. More...
 
void UpdateWindowLevel ()
 
 vtkBooleanMacro (ShowAnnotations, int)
 Set the annotation status. 0: annotations are not visible 1: annotations are visible. More...
 
 vtkBooleanMacro (ShowScalarBar, int)
 Set the visibility of the scalar bar. 0: scalar bar is not visible 1: scalar bar is visible. More...
 
 vtkGetMacro (ShowAnnotations, int)
 Get the annotation status. 0: annotations are not visible 1: annotations are visible. More...
 
 vtkGetMacro (ShowScalarBar, int)
 Get the visibility of the scalar bar. 0: scalar bar is not visible 1: scalar bar is visible. More...
 
 vtkGetMacro (IsColor, bool)
 Get information about the color of the image. true: multi-channels image (i.e. color) false: single-channel image (i.e. black and white) More...
 
 vtkGetMacro (IntersectionLineWidth, float)
 Get the linewidth for added dataset in the scene (when using AddDataSet) More...
 
 vtkGetObjectMacro (CornerAnnotation, vtkCornerAnnotation)
 Get the corner annotation. More...
 
 vtkGetObjectMacro (ScalarBarActor, vtkScalarBarActor)
 Get the scalar bar actor. This instance follows the color window/level of the viewer. More...
 
 vtkGetObjectMacro (OrientationMatrix, vtkMatrix4x4)
 The OrientationMatrix instance (GetOrientationMatrix()) is a very important added feature of this viewer. It describes the rotation and translation to apply to the image bouding box (axis aligned) to the world coordinate system. More...
 
 vtkGetObjectMacro (LookupTable, vtkLookupTable)
 
 vtkGetObjectMacro (TextProperty, vtkTextProperty)
 Get a pointer to the current vtkTextProperty. More...
 
 vtkSetMacro (IntersectionLineWidth, float)
 Set the linewidth for added dataset in the scene (when using AddDataSet) More...
 
 vtkTypeRevisionMacro (vtkViewImage, vtkImageViewer2)
 

Static Public Member Functions

static vtkViewImage2DNew ()
 Convenient method to access the constructor. More...
 

Protected Member Functions

virtual void InitializeSlicePlane (void)
 This method is called each time the orientation changes (SetViewOrientation()) and sets the appropriate color to the slice plane. Red: R-L direction –> sagittal orientation Green: A-P direction –> coronal orientation Blue: I-S direction –> axial orientation. More...
 
virtual void InstallPipeline (void)
 Overwrite of the Superclass InstallPipeline() method in order to set up the home made InteractorStyle, and make it observe all events we need. More...
 
virtual void PostUpdateOrientation (void)
 
virtual void SetAnnotationsFromOrientation (void)
 
virtual void SetAnnotationToConvention (void)
 
virtual int SetCameraFromOrientation (void)
 
virtual int SetCameraToConvention (void)
 
virtual void SetImplicitPlaneFromOrientation (void)
 After the orientation has changed, it is crucial to adapt a couple of things according to new orientation. Thus UpdateOrientation() is here overwritten and calls PostUpdateOrientation(), where the SlicePlane, the Camera settings, the CornerAnnotation, and the SliceImplicitPlane are modified. More...
 
virtual void SetSlicePlaneFromOrientation (void)
 
virtual void SetSlicePlaneToConvention (unsigned int axis)
 
virtual void UpdateCenter (void)
 
virtual void UpdateCursor (void)
 Update the cursor position and the CornerAnnotation (top-left) according to current mouse position. More...
 
virtual void UpdateOrientation ()
 
virtual void UpdateSlicePlane (void)
 
 vtkViewImage2D ()
 
 ~vtkViewImage2D ()
 
- Protected Member Functions inherited from vtkViewImage
 vtkViewImage ()
 
 ~vtkViewImage ()
 

Protected Attributes

double CameraMotionVector [3]
 
vtkViewImage2DCommandCommand
 Access to the command of the viewer. This instance is in charge of observing the interactorstyle (GetInteractorStyle()) and update things accordingly in the view (i.e. the slice number when moving slice). More...
 
vtkMatrix4x4 * ConventionMatrix
 
vtkPointHandleRepresentation2D * Cursor
 Access to the actor corresponding to the cursor. It follows the mouse cursor everywhere it goes, and can be activated by pressing 'c'. More...
 
vtkCursor2D * CursorGenerator
 Access to the actor corresponding to the cursor. It follows the mouse cursor everywhere it goes, and can be activated by pressing 'c'. More...
 
char ImageInformation [64]
 
vtkInteractorStyleRubberBandZoom * InteractorStyleRubberZoom
 InteractorStyle used in this view. It is a vtkInteractorStyleImage2D by default but can be set to vtkInteractorStyleRubberBandZoom with SetInteractorStyleType(). Rubber band zoom is in beta. Prefer using default behaviour. More...
 
vtkInteractorStyle * InteractorStyleSwitcher
 
int InteractorStyleType
 
vtkOrientationAnnotationOrientationAnnotation
 Get the orientation annotation. This annotation describes the orientation of the slice plane, according to the rule Right(R)-Left(L) Anterior(A)-Posterior(P) Inferior(I)-Superior(S) More...
 
char SliceAndWindowInformation [64]
 
vtkSmartPointer< vtkPlane > SliceImplicitPlane
 
vtkPolyData * SlicePlane
 This polydata instance is a square colored (see InitializeSlicePlane()) according to the orientation of the view. It follows the image actor and is used by other view to display intersections between views. More...
 
double ViewCenter [3]
 
int ViewConvention
 
int ViewOrientation
 
double Zoom
 
- Protected Attributes inherited from vtkViewImage
vtkCornerAnnotation * CornerAnnotation
 
double CurrentPoint [3]
 
std::string DirectionAnnotationMatrix [3][2]
 
float IntersectionLineWidth
 
bool IsColor
 
double Level
 
vtkLookupTable * LookupTable
 
vtkMatrix4x4 * OrientationMatrix
 
vtkMatrixToLinearTransform * OrientationTransform
 
vtkScalarBarActor * ScalarBarActor
 
int ShowAnnotations
 
int ShowScalarBar
 
vtkTextProperty * TextProperty
 
double Window
 

Detailed Description

Basic class to handle 2D/3D items such as images and polydatas visualization in 2D.

Definition at line 100 of file vtkViewImage2D.h.

Member Enumeration Documentation

anonymous enum

The orientation of the view is a abstract representation of the object we are looking at. It results from the acquisition plane. Setting the View Orientation by calling SetViewOrientation() will imply the view to set its inner "slice" orientation. (slice orientation == 2 means plane of acquisition.)

Note
The view orientations defined here are orthogonal to the normal basis in the scanner. A very interesting improvement would be to define "oblique" view orientations for cardiac imaging, something like:

VIEW_ORIENTATION_SHORT_AXIS, VIEW_ORIENTATION_LONG_AXIS, and VIEW_ORIENTATION_FOUR_CHAMBER could define the different views that are usually used in cardiac imaging.

From this user-input information, the idea would be to evaluate which slice orientation does correspond to the requested view. This can be done by evaluating the dot product between the axis of acquisition and a pre-defined oblique axis that "should" correspond to the requested orientation...

Enumerator
VIEW_ORIENTATION_SAGITTAL 
VIEW_ORIENTATION_CORONAL 
VIEW_ORIENTATION_AXIAL 

Definition at line 132 of file vtkViewImage2D.h.

anonymous enum

Description:

Enumerator
VIEW_CONVENTION_RADIOLOGICAL 
VIEW_CONVENTION_NEUROLOGICAL 

Definition at line 142 of file vtkViewImage2D.h.

anonymous enum

Description: These types describe the behaviour of the interactor style.

Enumerator
INTERACTOR_STYLE_NAVIGATION 
INTERACTOR_STYLE_RUBBER_ZOOM 

Definition at line 153 of file vtkViewImage2D.h.

Enumerator
XY 
XZ 
YZ 

Definition at line 159 of file vtkViewImage2D.h.

Constructor & Destructor Documentation

vtkViewImage2D::vtkViewImage2D ( )
protected

Definition at line 124 of file vtkViewImage2D.cxx.

vtkViewImage2D::~vtkViewImage2D ( )
protected

Definition at line 174 of file vtkViewImage2D.cxx.

Member Function Documentation

template<class TContourContainer , class TPropertyContainer >
void vtkViewImage2D::AddContours ( TContourContainer &  iContours,
TPropertyContainer &  iProperty,
const bool &  iIntersection = true 
)
inline

Add contours with specific properties to the view.

Definition at line 454 of file vtkViewImage2D.h.

vtkActor * vtkViewImage2D::AddDataSet ( vtkPolyData *  polydata,
vtkProperty *  property = NULL,
const bool &  intersection = true,
const bool &  iDataVisibility = false 
)
virtual

Add a dataset to the view (has to be subclass of vtkPointSet). The dataset will be cut through the implicit slice plane (GetImplicitSlicePlane()). This results in a loss of dimensionality, i.e. tetrahedron will be displayed as triangles, triangles as lines, lines as points. A vtkProperty of the dataset can be specified.

Parameters
[in]datasetData to be displayed (shape, position, etc.)
[in]propertyProperty of the data to be displayed (color, opacity, etc.)
[in]intersectionDisplay projection or intersection of the dataset with the current slice
[in]iDataVisibilityVisibility of the current actor

Definition at line 891 of file vtkViewImage2D.cxx.

std::map< double, vtkActor * > vtkViewImage2D::ExtractActors ( vtkPolyData *  iDataSet,
ORIENTATION  iOrientation 
)

Definition at line 975 of file vtkViewImage2D.cxx.

void vtkViewImage2D::GetCameraFocalAndPosition ( double  focal[3],
double  pos[3] 
)

Set camera focal point and position.

Parameters
[out]focaldouble[3] containing the focal point of the camera
[out]posdouble[3] containing the position of the camera

Definition at line 745 of file vtkViewImage2D.cxx.

int vtkViewImage2D::GetInterpolate ( void  )
virtual

Get whether or not the interpolation between pixels should be activated. It is Off by default.

Returns
val 0: interpolation off, 1: interpolation on

Definition at line 876 of file vtkViewImage2D.cxx.

int vtkViewImage2D::GetSliceForWorldCoordinates ( double  pos[3])
virtual

Convert a world coordinate point into an image indices coordinate point.

Definition at line 616 of file vtkViewImage2D.cxx.

double * vtkViewImage2D::GetWorldCoordinatesForSlice ( int  slice)
virtual

Convert an indices coordinate point (image coordinates) into a world coordinate point.

Definition at line 628 of file vtkViewImage2D.cxx.

double * vtkViewImage2D::GetWorldCoordinatesFromDisplayPosition ( int  xy[2])
virtual

Useful method that transform a display position into a world corrdinate point.

Definition at line 766 of file vtkViewImage2D.cxx.

double * vtkViewImage2D::GetWorldCoordinatesFromDisplayPosition ( const int &  x,
const int &  y 
)
virtual

Definition at line 607 of file vtkViewImage2D.cxx.

void vtkViewImage2D::InitializeSlicePlane ( void  )
protectedvirtual

This method is called each time the orientation changes (SetViewOrientation()) and sets the appropriate color to the slice plane. Red: R-L direction –> sagittal orientation Green: A-P direction –> coronal orientation Blue: I-S direction –> axial orientation.

Definition at line 277 of file vtkViewImage2D.cxx.

void vtkViewImage2D::InstallPipeline ( void  )
protectedvirtual

Overwrite of the Superclass InstallPipeline() method in order to set up the home made InteractorStyle, and make it observe all events we need.

Definition at line 796 of file vtkViewImage2D.cxx.

static vtkViewImage2D* vtkViewImage2D::New ( )
static

Convenient method to access the constructor.

void vtkViewImage2D::PostUpdateOrientation ( void  )
protectedvirtual

Definition at line 1105 of file vtkViewImage2D.cxx.

void vtkViewImage2D::Reset ( void  )
virtual

Reset position - zoom - window/level to default.

Reimplemented from vtkViewImage.

Definition at line 715 of file vtkViewImage2D.cxx.

void vtkViewImage2D::ResetCamera ( void  )
virtual

Reset the camera in a nice way for the 2D view.

Reimplemented from vtkViewImage.

Definition at line 655 of file vtkViewImage2D.cxx.

void vtkViewImage2D::ResetPosition ( void  )
virtual

Reset the 3D position to center.

Definition at line 639 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetAnnotationsFromOrientation ( void  )
protectedvirtual
Todo:
surely there is a simpler way to do all of that !

Definition at line 1263 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetAnnotationToConvention ( void  )
protectedvirtual
Todo:
surely there is a simpler way to do all of that !

Definition at line 464 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetCameraFocalAndPosition ( double  focal[3],
double  pos[3] 
)

Set camera focal point and position.

Parameters
[in]focaldouble[3] containing the focal point of the camera
[in]posdouble[3] containing the position of the camera

Definition at line 724 of file vtkViewImage2D.cxx.

int vtkViewImage2D::SetCameraFromOrientation ( void  )
protectedvirtual

Definition at line 1139 of file vtkViewImage2D.cxx.

int vtkViewImage2D::SetCameraToConvention ( void  )
protectedvirtual

Definition at line 324 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetDefaultInteractionStyle ( void  )
inline

Set interaction style to Default mode: Left button: Window level Right button: Zoom Middle button: Pan Wheel: Throught volume.

Definition at line 376 of file vtkViewImage2D.h.

void vtkViewImage2D::SetImplicitPlaneFromOrientation ( void  )
protectedvirtual

After the orientation has changed, it is crucial to adapt a couple of things according to new orientation. Thus UpdateOrientation() is here overwritten and calls PostUpdateOrientation(), where the SlicePlane, the Camera settings, the CornerAnnotation, and the SliceImplicitPlane are modified.

Definition at line 1402 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetInterpolate ( const int &  val)
virtual

Set whether or not the interpolation between pixels should be activated. It is Off by default.

Parameters
[in]val0: interpolation off, 1: interpolation on

Definition at line 866 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetOrientationMatrix ( vtkMatrix4x4 *  matrix)
virtual

Reimplemented from vtkViewImage.

Definition at line 269 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetPanInteractionStyle ( void  )
inline

Set interaction style to Pan mode: All buttons: Pan.

Definition at line 404 of file vtkViewImage2D.h.

void vtkViewImage2D::SetPickInteractionStyle ( void  )
inline

Set interaction style to Zoom mode: The actor the mouse is highlighted in addition to the Default Mode.

Definition at line 418 of file vtkViewImage2D.h.

void vtkViewImage2D::SetShowAnnotations ( const int &  iShowAnnotations)
virtual

Set the annotation visibility.

Reimplemented from vtkViewImage.

Definition at line 235 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetSlice ( int  s)
virtual

Set/Get the current slice to display (depending on the orientation this can be in X, Y or Z).

Reimplemented from vtkViewImage.

Definition at line 559 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetSlicePlaneFromOrientation ( void  )
protectedvirtual
 These lines tell the slice plane which color it should be

/

Todo:
We should allow more colors...

Definition at line 1118 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetSlicePlaneToConvention ( unsigned int  axis)
protectedvirtual

Definition at line 537 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetViewConvention ( int  convention)
virtual
Todo:
why not adding cardiologic conventions with oblique points of

actually we can't: oblique point of view implies resampling data: loss

data... and we don't want that, do we ?

Definition at line 187 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetViewOrientation ( int  orientation)
virtual
Todo:
: in terms of view orientation here we can add some cardiac specific: short axis, long axis, and 4-chambers !!! exiting !

Definition at line 243 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetWorldCoordinates ( double  pos[3])
virtual

The world is not always what we think it is ... Use this method to move the viewer slice such that the position (in world coordinates) given by the arguments is contained by the slice plane. If the given position is outside the bounds of the image, then the slice will be as close as possible.

Implements vtkViewImage.

Definition at line 317 of file vtkViewImage2D.cxx.

void vtkViewImage2D::SetZoomInteractionStyle ( void  )
inline

Set interaction style to Zoom mode: All buttons: Zoom.

Definition at line 390 of file vtkViewImage2D.h.

void vtkViewImage2D::SynchronizeViews ( bool  iSynchronize)
inline

Definition at line 433 of file vtkViewImage2D.h.

virtual void vtkViewImage2D::Update ( void  )
inlinevirtual

Update the orientation.

Reimplemented from vtkViewImage.

Definition at line 366 of file vtkViewImage2D.h.

void vtkViewImage2D::UpdateCenter ( void  )
protectedvirtual

Definition at line 1068 of file vtkViewImage2D.cxx.

void vtkViewImage2D::UpdateCursor ( void  )
protectedvirtual

Update the cursor position and the CornerAnnotation (top-left) according to current mouse position.

Todo:
This may has to be modified as with this configuration, the user has

Definition at line 1426 of file vtkViewImage2D.cxx.

void vtkViewImage2D::UpdateOrientation ( )
protectedvirtual

Definition at line 309 of file vtkViewImage2D.cxx.

void vtkViewImage2D::UpdateSlicePlane ( void  )
protectedvirtual

Definition at line 577 of file vtkViewImage2D.cxx.

vtkViewImage2D::vtkBooleanMacro ( Interpolate  ,
int   
)
vtkViewImage2D::vtkBooleanMacro ( ShowAnnotations  ,
int   
)

Show/Hide the annotations.

vtkViewImage2D::vtkGetMacro ( ViewOrientation  ,
int   
)

Get the view orientation.

Returns
0: radiological, 1: anatomic

Instead of setting the slice orientation to an axis (YZ - XZ - XY), you can force the view to be axial (foot-head), coronal (front-back), or sagittal (left-right). It will just use the OrientationMatrix (GetOrientationMatrix()) to check which slice orientation to pick.

vtkViewImage2D::vtkGetMacro ( ViewConvention  ,
int   
)

Get the view orientation.

Returns
0: sagittal, 1: coronal, 2: axial

The ViewConvention instance explains where to place the camera around the patient. Default behaviour is Radiological convention, meaning we respectively look at the patient from his feet, his face and his left ear. For Neurological convention, we respectively look from the top of his head, the the back of his head, and his left ear.

vtkViewImage2D::vtkGetMacro ( Zoom  ,
double   
)

Get the zoom factor in the views.

Returns
double representing the zoom factor
vtkViewImage2D::vtkGetMacro ( ShowAnnotations  ,
int   
)

Get the annotation visibility.

Returns
0: not visible, 1:visible
vtkViewImage2D::vtkGetObjectMacro ( SlicePlane  ,
vtkPolyData   
)

Get the polydata representing the Slice Plane.

The SlicePlane instance (GetSlicePlane()) is the polygonal square corresponding to the slice plane, it is updated each time the slice changes, and is color-coded according to conventions

vtkViewImage2D::vtkGetObjectMacro ( OrientationAnnotation  ,
vtkOrientationAnnotation   
)

Get the orientation annotation. This annotation describes the orientation of the slice plane, according to the rule Right(R)-Left(L) Anterior(A)-Posterior(P) Inferior(I)-Superior(S)

vtkViewImage2D::vtkGetObjectMacro ( Command  ,
vtkViewImage2DCommand   
)

Access to the command of the viewer. This instance is in charge of observing the interactorstyle (GetInteractorStyle()) and update things accordingly in the view (i.e. the slice number when moving slice).

vtkViewImage2D::vtkGetObjectMacro ( Cursor  ,
vtkPointHandleRepresentation2D   
)

Access to the actor corresponding to the cursor. It follows the mouse cursor everywhere it goes, and can be activated by pressing 'c'

vtkViewImage2D::vtkGetObjectMacro ( CursorGenerator  ,
vtkCursor2D   
)
vtkViewImage2D::vtkGetVector3Macro ( CameraMotionVector  ,
double   
)

Get the camera motion vector.

Returns
double[3] containing the motion vector
vtkViewImage2D::vtkGetVector3Macro ( ViewCenter  ,
double   
)

Get the view center.

Access to the position of the center of the view. CAUTION: for the moment this feature is de-activated because updating it slows down the visualization process.

Returns
double[3] containing the center of the view
vtkViewImage2D::vtkSetMacro ( Zoom  ,
double   
)

Set the zoom factor in the views.

vtkViewImage2D::vtkSetVector3Macro ( CameraMotionVector  ,
double   
)

Set the camera motion vector.

vtkViewImage2D::vtkTypeRevisionMacro ( vtkViewImage2D  ,
vtkViewImage   
)

Member Data Documentation

double vtkViewImage2D::CameraMotionVector[3]
protected

Definition at line 611 of file vtkViewImage2D.h.

vtkViewImage2DCommand* vtkViewImage2D::Command
protected

Access to the command of the viewer. This instance is in charge of observing the interactorstyle (GetInteractorStyle()) and update things accordingly in the view (i.e. the slice number when moving slice).

Definition at line 589 of file vtkViewImage2D.h.

vtkMatrix4x4* vtkViewImage2D::ConventionMatrix
protected

Definition at line 560 of file vtkViewImage2D.h.

vtkPointHandleRepresentation2D* vtkViewImage2D::Cursor
protected

Access to the actor corresponding to the cursor. It follows the mouse cursor everywhere it goes, and can be activated by pressing 'c'.

Definition at line 594 of file vtkViewImage2D.h.

vtkCursor2D* vtkViewImage2D::CursorGenerator
protected

Access to the actor corresponding to the cursor. It follows the mouse cursor everywhere it goes, and can be activated by pressing 'c'.

Definition at line 599 of file vtkViewImage2D.h.

char vtkViewImage2D::ImageInformation[64]
protected

Definition at line 608 of file vtkViewImage2D.h.

vtkInteractorStyleRubberBandZoom* vtkViewImage2D::InteractorStyleRubberZoom
protected

InteractorStyle used in this view. It is a vtkInteractorStyleImage2D by default but can be set to vtkInteractorStyleRubberBandZoom with SetInteractorStyleType(). Rubber band zoom is in beta. Prefer using default behaviour.

Definition at line 583 of file vtkViewImage2D.h.

vtkInteractorStyle* vtkViewImage2D::InteractorStyleSwitcher
protected

Definition at line 577 of file vtkViewImage2D.h.

int vtkViewImage2D::InteractorStyleType
protected

Definition at line 603 of file vtkViewImage2D.h.

vtkOrientationAnnotation* vtkViewImage2D::OrientationAnnotation
protected

Get the orientation annotation. This annotation describes the orientation of the slice plane, according to the rule Right(R)-Left(L) Anterior(A)-Posterior(P) Inferior(I)-Superior(S)

Definition at line 575 of file vtkViewImage2D.h.

char vtkViewImage2D::SliceAndWindowInformation[64]
protected

Definition at line 607 of file vtkViewImage2D.h.

vtkSmartPointer< vtkPlane > vtkViewImage2D::SliceImplicitPlane
protected

Definition at line 562 of file vtkViewImage2D.h.

vtkPolyData* vtkViewImage2D::SlicePlane
protected

This polydata instance is a square colored (see InitializeSlicePlane()) according to the orientation of the view. It follows the image actor and is used by other view to display intersections between views.

Definition at line 569 of file vtkViewImage2D.h.

double vtkViewImage2D::ViewCenter[3]
protected

Definition at line 605 of file vtkViewImage2D.h.

int vtkViewImage2D::ViewConvention
protected

Definition at line 602 of file vtkViewImage2D.h.

int vtkViewImage2D::ViewOrientation
protected

Definition at line 601 of file vtkViewImage2D.h.

double vtkViewImage2D::Zoom
protected

Definition at line 610 of file vtkViewImage2D.h.


The documentation for this class was generated from the following files: