IGSTK
Public Member Functions | Protected Member Functions | Friends | List of all members
igstk::View Class Reference

Display graphical representations of surgical scenes. More...

#include <igstkView.h>

Inheritance diagram for igstk::View:
Inheritance graph
[legend]
Collaboration diagram for igstk::View:
Collaboration graph
[legend]

Public Member Functions

 igstkStandardClassTraitsMacro (View, Object)
 Macro with standard traits declarations. More...
 
void SetRefreshRate (double frequency)
 Set the desired frequency for refreshing the view. More...
 
void RequestAddObject (ObjectRepresentation *object)
 Add an object representation to the list of children and associate it with a specific view. More...
 
void RequestAddAnnotation2D (Annotation2D::Pointer annotation)
 Add annotation to the view. More...
 
void RequestRemoveObject (ObjectRepresentation *object)
 Remove the object passed as arguments from the list of children, only if it is associated to a particular view. More...
 
void RequestSaveScreenShot (const std::string &filename)
 Request to save a screen shot into a file. More...
 
void Print (std::ostream &os,::itk::Indent indent=0) const
 Print the object information in a stream. More...
 
void SetLogger (LoggerType *logger)
 
void RequestResetCamera ()
 Request to return the camera to a known position. More...
 
void RequestStart ()
 Request Start the periodic refreshing of the view. More...
 
void RequestStop ()
 Request Stopping the periodic refreshing of the view. More...
 
void SetCameraPosition (double x, double y, double z)
 Set Camera position. More...
 
void SetCameraFocalPoint (double x, double y, double z)
 Set camera focal point. More...
 
void SetCameraViewUp (double vx, double vy, double vz)
 Set Camera View Up vector. More...
 
void SetCameraClippingRange (double dNear, double dFar)
 Set Clipping range. More...
 
void SetCameraParallelProjection (bool flag)
 Turn on/off parallel projection. More...
 
void SetRendererBackgroundColor (double red, double green, double blue)
 Set renderer background color. More...
 
void SetCameraZoomFactor (double rate)
 Set camera zoom factor. More...
 
- Public Member Functions inherited from igstk::Object
virtual const char * GetNameOfClass () const
 
void SetLogger (LoggerType *logger)
 Connect the Logger for this class. More...
 
void RemoveObserver (unsigned long tag) const
 

Protected Member Functions

LoggerTypeGetLogger () const
 Set up variables, types and methods related to the Logger. More...
 
 View ()
 
virtual ~View (void)
 
virtual void PrintSelf (std::ostream &os, itk::Indent indent) const
 Print the object information in a stream. More...
 
void SetInteractorStyle (vtkInteractorStyle *style)
 Set the interactor style in the derived classes. More...
 
void RequestSetRenderWindowSize (int width, int height)
 Set the size of the render window. More...
 
void RequestInitializeRenderWindowInteractor ()
 Request initialize the RenderWindow interactor. More...
 
void SetPickedPointCoordinates (double xPosition, double yPosition)
 Sets the coordinates of the point picked. More...
 
- Protected Member Functions inherited from igstk::Object
LoggerTypeGetLogger () const
 
 Object (void)
 Constructor is protected in order to enforce the use of the New() operator. More...
 
virtual ~Object (void)
 
void RegisterObservedObject (const ::igstk::Object *object, unsigned long tag)
 Register observed objects in an internal array so that they can be disconnected upon destruction. More...
 
void RemoveFromObservedObjects ()
 Remove observers that this object may have connected to other objects. More...
 

Friends

class ViewProxyBase
 

Additional Inherited Members

- Public Types inherited from igstk::Object
typedef Object Self
 General Typedefs. More...
 
typedef ::itk::Object Superclass
 
typedef ::itk::SmartPointer< SelfPointer
 
typedef ::itk::SmartPointer
< const Self
ConstPointer
 
typedef igstk::Logger LoggerType
 
- Static Public Member Functions inherited from igstk::Object
static Pointer New (void)
 

Detailed Description

Display graphical representations of surgical scenes.

The functionality of the View class is to aggregate all the graphical representations of spatial objects into one scene. igstk::View2D and igstk::View3D classes are derived from this class for 2D and 3D viewing capabilities. The view class encapsulate VTK classes into a restrictive API subjected to control of a state machine.

igstkView.png
State Machine Diagram
See Also
View2D
View3D

Definition at line 73 of file igstkView.h.

Constructor & Destructor Documentation

igstk::View::View ( )
protected
virtual igstk::View::~View ( void  )
protectedvirtual

Member Function Documentation

igstk::View::igstkStandardClassTraitsMacro ( View  ,
Object   
)

Macro with standard traits declarations.

void igstk::View::SetRefreshRate ( double  frequency)

Set the desired frequency for refreshing the view.

It is not worth to attempt to go faster than your monitor, nor more than double than your trackers

void igstk::View::RequestAddObject ( ObjectRepresentation object)

Add an object representation to the list of children and associate it with a specific view.

void igstk::View::RequestAddAnnotation2D ( Annotation2D::Pointer  annotation)

Add annotation to the view.

void igstk::View::RequestRemoveObject ( ObjectRepresentation object)

Remove the object passed as arguments from the list of children, only if it is associated to a particular view.

void igstk::View::RequestSaveScreenShot ( const std::string &  filename)

Request to save a screen shot into a file.

The file format MUST be PNG in order to have lossless compression. This method will trigger an extra rendering of the scene in order to ensure that the image is fresh.

void igstk::View::Print ( std::ostream &  os,
::itk::Indent  indent = 0 
) const

Print the object information in a stream.

LoggerType* igstk::View::GetLogger ( ) const
protected

Set up variables, types and methods related to the Logger.

void igstk::View::SetLogger ( LoggerType logger)
void igstk::View::RequestResetCamera ( )

Request to return the camera to a known position.

void igstk::View::RequestStart ( )

Request Start the periodic refreshing of the view.

void igstk::View::RequestStop ( )

Request Stopping the periodic refreshing of the view.

void igstk::View::SetCameraPosition ( double  x,
double  y,
double  z 
)

Set Camera position.

void igstk::View::SetCameraFocalPoint ( double  x,
double  y,
double  z 
)

Set camera focal point.

void igstk::View::SetCameraViewUp ( double  vx,
double  vy,
double  vz 
)

Set Camera View Up vector.

void igstk::View::SetCameraClippingRange ( double  dNear,
double  dFar 
)

Set Clipping range.

void igstk::View::SetCameraParallelProjection ( bool  flag)

Turn on/off parallel projection.

void igstk::View::SetRendererBackgroundColor ( double  red,
double  green,
double  blue 
)

Set renderer background color.

void igstk::View::SetCameraZoomFactor ( double  rate)

Set camera zoom factor.

virtual void igstk::View::PrintSelf ( std::ostream &  os,
itk::Indent  indent 
) const
protectedvirtual

Print the object information in a stream.

Reimplemented from igstk::Object.

void igstk::View::SetInteractorStyle ( vtkInteractorStyle *  style)
protected

Set the interactor style in the derived classes.

void igstk::View::RequestSetRenderWindowSize ( int  width,
int  height 
)
protected

Set the size of the render window.

void igstk::View::RequestInitializeRenderWindowInteractor ( )
protected

Request initialize the RenderWindow interactor.

void igstk::View::SetPickedPointCoordinates ( double  xPosition,
double  yPosition 
)
protected

Sets the coordinates of the point picked.

Friends And Related Function Documentation

friend class ViewProxyBase
friend

Definition at line 140 of file igstkView.h.


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