vtkMRMLSliceNode Class Reference

#include <vtkMRMLSliceNode.h>

Inheritance diagram for vtkMRMLSliceNode:
vtkMRMLNode vtkObject

List of all members.

Public Types

enum  { CenteredJumpSlice = 0, OffsetJumpSlice }
enum  { AutomaticSliceSpacingMode = 0, PrescribedSliceSpacingMode }

Public Member Functions

virtual void Copy (vtkMRMLNode *node)
virtual vtkMRMLNodeCreateNodeInstance ()
charGetLayoutName ()
virtual const charGetNodeTagName ()
void JumpAllSlices (double r, double a, double s)
void JumpSlice (double r, double a, double s)
void JumpSliceByCentering (double r, double a, double s)
void JumpSliceByOffsetting (int k, double r, double a, double s)
void JumpSliceByOffsetting (double r, double a, double s)
int Matrix4x4AreEqual (vtkMatrix4x4 *m1, vtkMatrix4x4 *m2)
void PrintSelf (ostream &os, vtkIndent indent)
virtual void ReadXMLAttributes (const char **atts)
void RotateToVolumePlane (vtkMRMLVolumeNode *volumeNode)
void SetDimensions (unsigned int x, unsigned int y, unsigned int z)
void SetFieldOfView (double x, double y, double z)
void SetJumpModeToCentered ()
void SetJumpModeToOffset ()
void SetLayoutGrid (int rows, int columns)
virtual void SetLayoutGridColumns (int cols)
virtual void SetLayoutGridRows (int rows)
void SetLayoutName (const char *layoutName)
void SetOrientationToAxial ()
void SetOrientationToCoronal ()
void SetOrientationToReformat ()
void SetOrientationToSagittal ()
void SetSliceSpacingModeToAutomatic ()
void SetSliceSpacingModeToPrescribed ()
void SetSliceToRASByNTP (double Nx, double Ny, double Nz, double Tx, double Ty, double Tz, double Px, double Py, double Pz, int Orientation)
void UpdateMatrices ()
virtual void UpdateScene (vtkMRMLScene *)
 vtkBooleanMacro (UseLabelOutline, int)
 vtkGetMacro (ActiveSlice, int)
 vtkGetMacro (SliceSpacingMode, int)
 vtkGetMacro (JumpMode, int)
 vtkGetMacro (LayoutGridColumns, int)
 vtkGetMacro (LayoutGridRows, int)
 vtkGetMacro (UseLabelOutline, int)
 vtkGetMacro (WidgetVisible, int)
 vtkGetMacro (SliceVisible, int)
 vtkGetObjectMacro (XYToRAS, vtkMatrix4x4)
 vtkGetObjectMacro (XYToSlice, vtkMatrix4x4)
 vtkGetObjectMacro (SliceToRAS, vtkMatrix4x4)
 vtkGetStringMacro (OrientationIntentString)
 vtkGetStringMacro (OrientationString)
 vtkGetVector3Macro (PrescribedSliceSpacing, double)
 vtkGetVector3Macro (Dimensions, unsigned int)
 vtkGetVector3Macro (FieldOfView, double)
 vtkSetMacro (ActiveSlice, int)
 vtkSetMacro (SliceSpacingMode, int)
 vtkSetMacro (JumpMode, int)
 vtkSetMacro (UseLabelOutline, int)
 vtkSetMacro (WidgetVisible, int)
 vtkSetMacro (SliceVisible, int)
 vtkSetObjectMacro (SliceToRAS, vtkMatrix4x4)
 vtkSetStringMacro (OrientationIntentString)
 vtkSetStringMacro (OrientationString)
 vtkSetVector3Macro (PrescribedSliceSpacing, double)
 vtkTypeMacro (vtkMRMLSliceNode, vtkMRMLNode)
virtual void WriteXML (ostream &of, int indent)

Static Public Member Functions

static vtkMRMLSliceNodeNew ()

Protected Member Functions

void operator= (const vtkMRMLSliceNode &)
 vtkMRMLSliceNode (const vtkMRMLSliceNode &)
 vtkMRMLSliceNode ()
 ~vtkMRMLSliceNode ()

Protected Attributes

int ActiveSlice
unsigned int Dimensions [3]
double FieldOfView [3]
int JumpMode
int LayoutGridColumns
int LayoutGridRows
charOrientationIntentString
charOrientationString
double PrescribedSliceSpacing [3]
int SliceSpacingMode
vtkMatrix4x4 * SliceToRAS
int SliceVisible
int UseLabelOutline
int WidgetVisible
vtkMatrix4x4 * XYToRAS
vtkMatrix4x4 * XYToSlice

Member Enumeration Documentation

anonymous enum

Enum to specify the method of jumping slices

Enumerator:
CenteredJumpSlice 
OffsetJumpSlice 
anonymous enum

Enum to specify whether the slice spacing is automatically determined or prescribed

Enumerator:
AutomaticSliceSpacingMode 
PrescribedSliceSpacingMode 

Constructor & Destructor Documentation

vtkMRMLSliceNode::vtkMRMLSliceNode (  )  [protected]
vtkMRMLSliceNode::~vtkMRMLSliceNode (  )  [protected]
vtkMRMLSliceNode::vtkMRMLSliceNode ( const vtkMRMLSliceNode  )  [protected]

Member Function Documentation

void vtkMRMLSliceNode::Copy ( vtkMRMLNode node  )  [virtual]
vtkMRMLNode * vtkMRMLSliceNode::CreateNodeInstance (  )  [virtual]

Create instance of the default node. Like New only virtual NOTE: Subclasses should implement this method

Implements vtkMRMLNode.

References autoSlicerTracto2regions::ret.

char* vtkMRMLSliceNode::GetLayoutName (  )  [inline]
virtual const char* vtkMRMLSliceNode::GetNodeTagName (  )  [inline, virtual]

Get node XML tag name (like Volume, Model)

Implements vtkMRMLNode.

void vtkMRMLSliceNode::JumpAllSlices ( double  r,
double  a,
double  s 
)
void vtkMRMLSliceNode::JumpSlice ( double  r,
double  a,
double  s 
)

Set the RAS offset of the Slice to the passed values. JumpSlice and JumpAllSlices use the JumpMode to determine how to jump.

References CenteredJumpSlice, JumpMode, JumpSliceByCentering(), JumpSliceByOffsetting(), and OffsetJumpSlice.

Referenced by JumpAllSlices(), vtkNeuroNavLogic::UpdateCrosshair(), vtkOpenIGTLinkIFLogic::UpdateSliceNode(), and vtkNeuroNavLogic::UpdateSliceNode().

void vtkMRMLSliceNode::JumpSliceByCentering ( double  r,
double  a,
double  s 
)

References ActiveSlice, and UpdateMatrices().

Referenced by JumpSlice().

void vtkMRMLSliceNode::JumpSliceByOffsetting ( int  k,
double  r,
double  a,
double  s 
)
void vtkMRMLSliceNode::JumpSliceByOffsetting ( double  r,
double  a,
double  s 
)
int vtkMRMLSliceNode::Matrix4x4AreEqual ( vtkMatrix4x4 *  m1,
vtkMatrix4x4 *  m2 
)

helper for comparing to matrices TODO: is there a standard VTK method?

References j.

Referenced by UpdateMatrices().

vtkMRMLSliceNode * vtkMRMLSliceNode::New (  )  [static]
void vtkMRMLSliceNode::operator= ( const vtkMRMLSliceNode  )  [protected]

Reimplemented from vtkMRMLNode.

void vtkMRMLSliceNode::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
void vtkMRMLSliceNode::ReadXMLAttributes ( const char **  atts  )  [virtual]
void vtkMRMLSliceNode::RotateToVolumePlane ( vtkMRMLVolumeNode volumeNode  ) 

adjusts the slice node to align with the native space of the image data so that no oblique resampling occurs when rendering (helps to see original acquisition data and for obluique volumes with few slices).

References vtkMRMLVolumeNode::GetIJKToRASMatrix(), vtkMRMLTransformNode::GetMatrixTransformToWorld(), vtkMRMLTransformableNode::GetParentTransformNode(), vtkMRMLTransformNode::IsTransformToWorldLinear(), len, vtkMRMLNode::Modified(), New(), SetOrientationToReformat(), and SliceToRAS.

void vtkMRMLSliceNode::SetDimensions ( unsigned int  x,
unsigned int  y,
unsigned int  z 
)

References Dimensions, and UpdateMatrices().

void vtkMRMLSliceNode::SetFieldOfView ( double  x,
double  y,
double  z 
)
void vtkMRMLSliceNode::SetJumpModeToCentered (  ) 

References CenteredJumpSlice.

void vtkMRMLSliceNode::SetJumpModeToOffset (  ) 

References OffsetJumpSlice.

void vtkMRMLSliceNode::SetLayoutGrid ( int  rows,
int  columns 
)

Set the number of rows and columns to use in a LightBox display of the node

References ActiveSlice, Dimensions, double(), FieldOfView, LayoutGridColumns, LayoutGridRows, and UpdateMatrices().

Referenced by vtkSlicerSliceControllerWidget::SliceViewerLayoutConfig().

void vtkMRMLSliceNode::SetLayoutGridColumns ( int  cols  )  [virtual]
void vtkMRMLSliceNode::SetLayoutGridRows ( int  rows  )  [virtual]
void vtkMRMLSliceNode::SetLayoutName ( const char layoutName  )  [inline]
void vtkMRMLSliceNode::SetOrientationToAxial (  ) 

'standard' radiological convention views of patient space these calls adjust the SliceToRAS matrix to position the slice cutting plane

References SliceToRAS, and UpdateMatrices().

Referenced by vtkOpenIGTLinkIFGUI::ChangeSlicePlaneDriver(), vtkSlicerSliceControllerWidget::UpdateOrientation(), vtkOpenIGTLinkIFLogic::UpdateSliceNode(), vtkNeuroNavLogic::UpdateSliceNode(), vtkSlicerSliceLogic::UpdateSliceNodeFromLayout(), and vtkMRMLSliceNode().

void vtkMRMLSliceNode::SetOrientationToCoronal (  ) 
void vtkMRMLSliceNode::SetOrientationToReformat (  ) 

General 'reformat' view that allows for multiplanar reformat

Referenced by RotateToVolumePlane(), vtkProstateNavLogic::SetSliceViewFromVolume(), and vtkSlicerSliceControllerWidget::UpdateOrientation().

void vtkMRMLSliceNode::SetOrientationToSagittal (  ) 
void vtkMRMLSliceNode::SetSliceSpacingModeToAutomatic (  ) 
void vtkMRMLSliceNode::SetSliceSpacingModeToPrescribed (  ) 
void vtkMRMLSliceNode::SetSliceToRASByNTP ( double  Nx,
double  Ny,
double  Nz,
double  Tx,
double  Ty,
double  Tz,
double  Px,
double  Py,
double  Pz,
int  Orientation 
)

Set the SliceToRAS matrix according to the position and orientation of the locator: N(x, y, z) - the direction vector of the locator T(x, y, z) - the transverse direction vector of the locator P(x, y, z) - the tip location of the locator All the above values are in RAS space.

References Console::c, mathExample::n, SliceToRAS, NodeSelector::t, and UpdateMatrices().

Referenced by vtkOpenIGTLinkIFLogic::UpdateSliceNode(), and vtkNeuroNavLogic::UpdateSliceNode().

void vtkMRMLSliceNode::UpdateMatrices (  ) 
void vtkMRMLSliceNode::UpdateScene ( vtkMRMLScene scene  )  [virtual]

Updates other nodes in the scene depending on this node or updates this node if it depends on other nodes when the scene is read in This method is called automatically by XML parser after all nodes are created

Reimplemented from vtkMRMLNode.

References GetLayoutName(), vtkMRMLScene::GetNthNodeByClass(), vtkMRMLScene::GetNumberOfNodesByClass(), mathExample::n, and vtkMRMLScene::RemoveNodeNoNotify().

vtkMRMLSliceNode::vtkBooleanMacro ( UseLabelOutline  ,
int   
)
vtkMRMLSliceNode::vtkGetMacro ( ActiveSlice  ,
int   
)
vtkMRMLSliceNode::vtkGetMacro ( SliceSpacingMode  ,
int   
)

Get/Set the slice spacing mode. Slice spacing can be automatically calculated using GetLowestVolumeSliceSpacing() or prescribed

vtkMRMLSliceNode::vtkGetMacro ( JumpMode  ,
int   
)
vtkMRMLSliceNode::vtkGetMacro ( LayoutGridColumns  ,
int   
)

Set/Get the number of columns to use ina LightBox display

vtkMRMLSliceNode::vtkGetMacro ( LayoutGridRows  ,
int   
)

Set/Get the number of rows to use ina LightBox display

vtkMRMLSliceNode::vtkGetMacro ( UseLabelOutline  ,
int   
)

Use the label outline filter on this slice?

vtkMRMLSliceNode::vtkGetMacro ( WidgetVisible  ,
int   
)

The visibility of the slice plane widget in the 3DViewer.

vtkMRMLSliceNode::vtkGetMacro ( SliceVisible  ,
int   
)

The visibility of the slice in the 3DViewer.

vtkMRMLSliceNode::vtkGetObjectMacro ( XYToRAS  ,
vtkMatrix4x4   
)

Matrix mapping from XY pixel coordinates on an image window into RAS world coordinates

vtkMRMLSliceNode::vtkGetObjectMacro ( XYToSlice  ,
vtkMatrix4x4   
)

Matrix mapping from XY pixel coordinates on an image window into slice coordinates in mm

vtkMRMLSliceNode::vtkGetObjectMacro ( SliceToRAS  ,
vtkMatrix4x4   
)

Mapping from RAS space onto the slice plane TODO: maybe this should be a quaternion and a translate to avoid shears/scales

vtkMRMLSliceNode::vtkGetStringMacro ( OrientationIntentString   ) 

Description The orientation that this slice was, for example, before being rotated to lie in the acquisition plane by RotateToVolumePlane

vtkMRMLSliceNode::vtkGetStringMacro ( OrientationString   ) 

Description A description of the current orientation

vtkMRMLSliceNode::vtkGetVector3Macro ( PrescribedSliceSpacing  ,
double   
)
vtkMRMLSliceNode::vtkGetVector3Macro ( Dimensions  ,
unsigned  int 
)

Number of samples in each direction -- note that the spacing is implicitly FieldOfView / Dimensions

vtkMRMLSliceNode::vtkGetVector3Macro ( FieldOfView  ,
double   
)

Size of the slice plane in millimeters

vtkMRMLSliceNode::vtkSetMacro ( ActiveSlice  ,
int   
)

Set/get the active slice in the lightbox. The active slice is shown in the 3D scene

vtkMRMLSliceNode::vtkSetMacro ( SliceSpacingMode  ,
int   
)
vtkMRMLSliceNode::vtkSetMacro ( JumpMode  ,
int   
)

Control how JumpSlice operates. CenteredJumpMode puts the specified RAS position in the center of the slice. OffsetJumpMode does not change the slice position, merely adjusts the slice offset to get the RAS position on the slice.

vtkMRMLSliceNode::vtkSetMacro ( UseLabelOutline  ,
int   
)
vtkMRMLSliceNode::vtkSetMacro ( WidgetVisible  ,
int   
)
vtkMRMLSliceNode::vtkSetMacro ( SliceVisible  ,
int   
)
vtkMRMLSliceNode::vtkSetObjectMacro ( SliceToRAS  ,
vtkMatrix4x4   
)
vtkMRMLSliceNode::vtkSetStringMacro ( OrientationIntentString   ) 
vtkMRMLSliceNode::vtkSetStringMacro ( OrientationString   ) 
vtkMRMLSliceNode::vtkSetVector3Macro ( PrescribedSliceSpacing  ,
double   
)

Set/get the slice spacing to use when the SliceSpacingMode is "Prescribed"

vtkMRMLSliceNode::vtkTypeMacro ( vtkMRMLSliceNode  ,
vtkMRMLNode   
)
void vtkMRMLSliceNode::WriteXML ( ostream &  of,
int  indent 
) [virtual]

Member Data Documentation

unsigned int vtkMRMLSliceNode::Dimensions[3] [protected]
double vtkMRMLSliceNode::FieldOfView[3] [protected]
vtkMatrix4x4* vtkMRMLSliceNode::SliceToRAS [protected]
vtkMatrix4x4* vtkMRMLSliceNode::XYToRAS [protected]
vtkMatrix4x4* vtkMRMLSliceNode::XYToSlice [protected]

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

Generated on 6 Apr 2011 for Slicer3 by  doxygen 1.6.1