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

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

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

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

Public Member Functions

virtual void Add2DPhantom (const unsigned int &i, vtkImageActor *input, vtkPolyData *in_bounds=NULL)
 
virtual vtkActor * AddDataSet (vtkDataSet *dataset, vtkProperty *property=NULL, const bool &intersection=true, const bool &iDataVisibility=false)
 
void ComputeDistances (double *n, double *origin)
 Compute the distance between 2 points. More...
 
void ComputeDistancesToSquare (vtkPlanes *planes)
 Compute the disctance from the actors to the surface. More...
 
bool GetCubeVisibility (void)
 Get the cube visibility. More...
 
vtkInteractorStyleImage3DGetInteractorStyle3D ()
 Get the interactor style for the vtkViewImage3D. More...
 
std::vector< vtkProp3D * > GetPlanesActors ()
 
bool GetShade (void)
 Get the shade. More...
 
virtual void Render (void)
 
void SetBoundsActorsVisibility (bool iVisibility)
 Set the bounds actors visibility. More...
 
void SetCubeVisibility (const bool &a)
 Set the cube visibility. More...
 
virtual void SetOrientationMatrix (vtkMatrix4x4 *matrix)
 
void SetShade (const bool &a)
 Set the shade. More...
 
virtual void SetSlice (int s)
 
virtual void SetSliceOrientation (int orientation)
 
void SetTriPlanarRenderingOff ()
 
void SetTriPlanarRenderingOn ()
 
void SetVolumeRenderingOff ()
 
void SetVolumeRenderingOn (const std::vector< vtkImageData * > &iImages, const std::vector< vtkPiecewiseFunction * > &iOpacities)
 
virtual void SetWorldCoordinates (double pos[3])
 
virtual void UpdateDisplayExtent ()
 
 vtkBooleanMacro (CubeVisibility, int)
 
 vtkBooleanMacro (Shade, int)
 
 vtkGetObjectMacro (VolumeActor, vtkVolume)
 
 vtkGetObjectMacro (VolumeProperty, vtkVolumeProperty)
 
 vtkGetObjectMacro (Command, vtkViewImage3DCommand)
 
 vtkTypeRevisionMacro (vtkViewImage3D, 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 Reset (void)
 Reset position - zoom - window/level to default. More...
 
virtual void ResetCamera (void)
 Reset the camera. More...
 
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 SetShowAnnotations (const int &iShowAnnotations)
 Change the visibility of the annotations. More...
 
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...
 
virtual void Update (void)
 
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 vtkViewImage3DNew ()
 Convenient method to access the constructor. More...
 

Protected Member Functions

void CleanVolumeRenderingVectors ()
 
virtual void InstallPipeline ()
 
virtual void SetupWidgets ()
 
virtual void UpdateOrientation ()
 
 vtkViewImage3D ()
 
 ~vtkViewImage3D ()
 
- Protected Member Functions inherited from vtkViewImage
 vtkViewImage ()
 
 ~vtkViewImage ()
 

Protected Attributes

std::vector< vtkActor * > BoundsActor
 
vtkImage3DCroppingBoxCallbackCallback
 
vtkViewImage3DCommandCommand
 
vtkAnnotatedCubeActor * Cube
 
vtkInteractorStyleImage3DInteractorStyle3D
 
std::vector< vtkVolume * > m_VolumeActors
 
std::vector
< vtkSmartVolumeMapper * > 
m_VolumeMappers
 
std::vector< vtkVolumeProperty * > m_VolumeProperties
 
vtkOrientationMarkerWidget * Marker
 
std::vector< vtkImageActor * > Phantom
 
std::vector< ImageActorCallback * > PhantomCallback
 
vtkSmartVolumeMapper * SmartVolumeMapper3D
 
vtkVolume * VolumeActor
 
vtkVolumeProperty * VolumeProperty
 
- 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 items such as images and polydatas visualization in 3D.

Definition at line 117 of file vtkViewImage3D.h.

Constructor & Destructor Documentation

vtkViewImage3D::vtkViewImage3D ( )
protected

Definition at line 200 of file vtkViewImage3D.cxx.

vtkViewImage3D::~vtkViewImage3D ( )
protected

Definition at line 231 of file vtkViewImage3D.cxx.

Member Function Documentation

void vtkViewImage3D::Add2DPhantom ( const unsigned int &  i,
vtkImageActor *  input,
vtkPolyData *  in_bounds = NULL 
)
virtual
Parameters
i
input
in_bounds

IMPORTANT NOTE

Adding a 2D actor in the 3D scene should be as simple as the next line instead of the code above...

Unfortunately it does not seem to work properly. But this is something we should investigate in because it would be much simpler

Definition at line 545 of file vtkViewImage3D.cxx.

vtkActor * vtkViewImage3D::AddDataSet ( vtkDataSet *  dataset,
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
dataset
property
intersection
iDataVisibility
Returns

Definition at line 656 of file vtkViewImage3D.cxx.

void vtkViewImage3D::CleanVolumeRenderingVectors ( )
protected

Definition at line 346 of file vtkViewImage3D.cxx.

void vtkViewImage3D::ComputeDistances ( double *  n,
double *  origin 
)

Compute the distance between 2 points.

Parameters
[in]ndouble pointer to the first point (double[3])
[in]origindouble pointer to the second point (double[3])

Definition at line 729 of file vtkViewImage3D.cxx.

void vtkViewImage3D::ComputeDistancesToSquare ( vtkPlanes *  planes)

Compute the disctance from the actors to the surface.

Parameters
[in]planesvtkPlanes pointer to the surface of interest

Definition at line 768 of file vtkViewImage3D.cxx.

bool vtkViewImage3D::GetCubeVisibility ( void  )
inline

Get the cube visibility.

Returns
true: visible, false: not visible

Definition at line 206 of file vtkViewImage3D.h.

vtkInteractorStyleImage3D * vtkViewImage3D::GetInteractorStyle3D ( )

Get the interactor style for the vtkViewImage3D.

Returns
pointer to the current vtkInteractorStyleImage3D

Definition at line 720 of file vtkViewImage3D.cxx.

std::vector< vtkProp3D * > vtkViewImage3D::GetPlanesActors ( )

Definition at line 811 of file vtkViewImage3D.cxx.

bool vtkViewImage3D::GetShade ( void  )
inline

Get the shade.

Returns
a true: enable, false: disable

Definition at line 226 of file vtkViewImage3D.h.

void vtkViewImage3D::InstallPipeline ( void  )
protectedvirtual

Definition at line 617 of file vtkViewImage3D.cxx.

static vtkViewImage3D* vtkViewImage3D::New ( )
static

Convenient method to access the constructor.

void vtkViewImage3D::Render ( void  )
virtual

Reimplemented from vtkViewImage.

Definition at line 308 of file vtkViewImage3D.cxx.

void vtkViewImage3D::SetBoundsActorsVisibility ( bool  iVisibility)

Set the bounds actors visibility.

Parameters
iVisibilitytrue: visible, false: not visible

Definition at line 599 of file vtkViewImage3D.cxx.

void vtkViewImage3D::SetCubeVisibility ( const bool &  a)
inline

Set the cube visibility.

Parameters
[in]atrue: visible, false: not visible

Definition at line 197 of file vtkViewImage3D.h.

void vtkViewImage3D::SetOrientationMatrix ( vtkMatrix4x4 *  matrix)
virtual
Parameters
matrix

Reimplemented from vtkViewImage.

Definition at line 704 of file vtkViewImage3D.cxx.

void vtkViewImage3D::SetShade ( const bool &  a)
inline

Set the shade.

Parameters
[in]atrue: enable, false: disable

Definition at line 217 of file vtkViewImage3D.h.

virtual void vtkViewImage3D::SetSlice ( int  s)
inlinevirtual

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 150 of file vtkViewImage3D.h.

virtual void vtkViewImage3D::SetSliceOrientation ( int  orientation)
inlinevirtual

Definition at line 151 of file vtkViewImage3D.h.

void vtkViewImage3D::SetTriPlanarRenderingOff ( )

Definition at line 526 of file vtkViewImage3D.cxx.

void vtkViewImage3D::SetTriPlanarRenderingOn ( )

Definition at line 513 of file vtkViewImage3D.cxx.

void vtkViewImage3D::SetupWidgets ( )
protectedvirtual

Definition at line 262 of file vtkViewImage3D.cxx.

void vtkViewImage3D::SetVolumeRenderingOff ( )

Definition at line 335 of file vtkViewImage3D.cxx.

void vtkViewImage3D::SetVolumeRenderingOn ( const std::vector< vtkImageData * > &  iImages,
const std::vector< vtkPiecewiseFunction * > &  iOpacities 
)

Definition at line 373 of file vtkViewImage3D.cxx.

virtual void vtkViewImage3D::SetWorldCoordinates ( double  pos[3])
inlinevirtual

Implements vtkViewImage.

Definition at line 239 of file vtkViewImage3D.h.

virtual void vtkViewImage3D::UpdateDisplayExtent ( )
inlinevirtual

Definition at line 163 of file vtkViewImage3D.h.

virtual void vtkViewImage3D::UpdateOrientation ( )
inlineprotectedvirtual

Definition at line 278 of file vtkViewImage3D.h.

vtkViewImage3D::vtkBooleanMacro ( CubeVisibility  ,
int   
)
vtkViewImage3D::vtkBooleanMacro ( Shade  ,
int   
)
vtkViewImage3D::vtkGetObjectMacro ( VolumeActor  ,
vtkVolume   
)

Get volume actor

vtkViewImage3D::vtkGetObjectMacro ( VolumeProperty  ,
vtkVolumeProperty   
)
vtkViewImage3D::vtkGetObjectMacro ( Command  ,
vtkViewImage3DCommand   
)
vtkViewImage3D::vtkTypeRevisionMacro ( vtkViewImage3D  ,
vtkViewImage   
)

Member Data Documentation

std::vector< vtkActor * > vtkViewImage3D::BoundsActor
protected

Definition at line 300 of file vtkViewImage3D.h.

vtkImage3DCroppingBoxCallback* vtkViewImage3D::Callback
protected

Definition at line 296 of file vtkViewImage3D.h.

vtkViewImage3DCommand* vtkViewImage3D::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 315 of file vtkViewImage3D.h.

vtkAnnotatedCubeActor* vtkViewImage3D::Cube
protected

Definition at line 307 of file vtkViewImage3D.h.

vtkInteractorStyleImage3D* vtkViewImage3D::InteractorStyle3D
protected

Definition at line 316 of file vtkViewImage3D.h.

std::vector<vtkVolume*> vtkViewImage3D::m_VolumeActors
protected

Definition at line 291 of file vtkViewImage3D.h.

std::vector<vtkSmartVolumeMapper*> vtkViewImage3D::m_VolumeMappers
protected

Definition at line 292 of file vtkViewImage3D.h.

std::vector<vtkVolumeProperty*> vtkViewImage3D::m_VolumeProperties
protected

Definition at line 293 of file vtkViewImage3D.h.

vtkOrientationMarkerWidget* vtkViewImage3D::Marker
protected

Definition at line 308 of file vtkViewImage3D.h.

std::vector< vtkImageActor * > vtkViewImage3D::Phantom
protected

Definition at line 298 of file vtkViewImage3D.h.

std::vector< ImageActorCallback * > vtkViewImage3D::PhantomCallback
protected

Definition at line 299 of file vtkViewImage3D.h.

vtkSmartVolumeMapper* vtkViewImage3D::SmartVolumeMapper3D
protected

Definition at line 285 of file vtkViewImage3D.h.

vtkVolume* vtkViewImage3D::VolumeActor
protected

Definition at line 289 of file vtkViewImage3D.h.

vtkVolumeProperty* vtkViewImage3D::VolumeProperty
protected

Definition at line 287 of file vtkViewImage3D.h.


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