SignContext Class Reference

#include <SignContext.h>

Collaboration diagram for SignContext:

Collaboration graph
[legend]
List of all members.

Detailed Description

Main class for overall application framework management.

The SignContext manages high level integration and is central to the application framework. There should be only one context for a given application. After creating a SignContext, make sure that all necessary variables have been set before starting the application. Examples of how to do this can be found in the main function of the example applications.

Author:
Eigil Samset


Public Member Functions

 vtkTypeRevisionMacro (SignContext, vtkKWApplication)
virtual void PrintSelf (ostream &os, vtkIndent indent)
void SetMRMLFile (std::string file)
 Initializes the context.
void Init (char *mrml, char *otcfg)
void SetGUI (SignUIBase *)
SignUIBaseGetGUI ()
void Start ()
void CleanUp ()
virtual SignContextGetApplication ()
void RenderAllWatched ()
 This method goes through all vtkRenderWindows in the renderWatch and calls Render() on them.
void AddProbes ()
 This method sets up probes as defined in the configuration file.
void UpdateProbes ()
 This method updates all probes/needles with the latest OpenTracker data.
SignViewerFindViewer (std::string name)
SignConfigurationGetConfiguration ()
 Returns a pointer to the current SignConfiguration object.
SignMRMLManagerGetMRMLManager ()
 Returns the current MRML manager.
void Use3DTexturesOn ()
 Indicates that 3D textures should be used.
void Use3DTexturesOff ()
 Indicates that 2D textures should be used.
bool Use3DTextures ()
 Returns if 3D textures are used.
void SetApplicationName (std::string name)
 Sets the application name that KWWidgets uses.
SignOTModuleGetOTModule ()
 Returns the current OpenTracker modules.
virtual int CreateLogDialog ()

Static Public Member Functions

static SignContextNew ()
static void InitTCL (int argc, char **)
static void SetTimePoint (vtkObject *caller, unsigned long, void *data, void *)
 Callback function for setting the current time point.
static void OnEventFromThread (vtkObject *caller, unsigned long, void *data, void *)
 Handles events from other threads.

Public Attributes

ot::Context * otc
RenderWindows renderWindowsUpdate
 vector that holds vtkRenderWindows that will be updated when doRender is set
SignViewers ViewerCollection
 vector of viewers (Sign2DViewer or Sign3DViewer)
int timePoint
 current timepoint for cine data
ColorNames colors
 static map of colors
SignStateManagerStateManager
 state manager object
bool annotation2D
 controls the visibility of 2D annotations
bool annotation3D
 controls the visibility of 3D annotations
bool hasSplashScreen
 flag that indicates if there is a splash screen
bool hasStatusBar
 flag that indicates if there is a status bar
bool hasTransferFunction
 Is true if there is any transfer function defined in the MRML tree.
bool stopRendering
 As long as this flag is true, render windows will not be updated.
std::string currentFiducialVolumeID
 Holds the ID of the volume that the current fiducials belong to (temporary).

Protected Member Functions

 SignContext ()
 ~SignContext ()
virtual void AddAboutText (ostream &)
virtual void AddAboutCopyrights (ostream &)
 SignContext (const SignContext &)
void operator= (const SignContext &)


Constructor & Destructor Documentation

SignContext::SignContext  )  [protected]
 

SignContext::~SignContext  )  [protected]
 

SignContext::SignContext const SignContext  )  [protected]
 


Member Function Documentation

void SignContext::AddAboutCopyrights ostream &   )  [protected, virtual]
 

void SignContext::AddAboutText ostream &   )  [protected, virtual]
 

void SignContext::AddProbes  ) 
 

This method sets up probes as defined in the configuration file.

void SignContext::CleanUp  ) 
 

int SignContext::CreateLogDialog  )  [virtual]
 

SignViewer * SignContext::FindViewer std::string  name  ) 
 

Finds a named Sign2DViewer

Parameters:
name name of the viewer to be found

SignContext * SignContext::GetApplication  )  [virtual]
 

SignConfiguration * SignContext::GetConfiguration  ) 
 

Returns a pointer to the current SignConfiguration object.

SignUIBase * SignContext::GetGUI  ) 
 

SignMRMLManager* SignContext::GetMRMLManager  )  [inline]
 

Returns the current MRML manager.

SignOTModule * SignContext::GetOTModule  ) 
 

Returns the current OpenTracker modules.

void SignContext::Init char *  mrml,
char *  otcfg
 

void SignContext::InitTCL int  argc,
char ** 
[static]
 

static SignContext* SignContext::New  )  [static]
 

void SignContext::OnEventFromThread vtkObject *  caller,
unsigned  long,
void *  data,
void * 
[static]
 

Handles events from other threads.

void SignContext::operator= const SignContext  )  [protected]
 

virtual void SignContext::PrintSelf ostream &  os,
vtkIndent  indent
[inline, virtual]
 

void SignContext::RenderAllWatched  ) 
 

This method goes through all vtkRenderWindows in the renderWatch and calls Render() on them.

void SignContext::SetApplicationName std::string  name  ) 
 

Sets the application name that KWWidgets uses.

void SignContext::SetGUI SignUIBase  ) 
 

void SignContext::SetMRMLFile std::string  file  ) 
 

Initializes the context.

void SignContext::SetTimePoint vtkObject *  caller,
unsigned  long,
void *  data,
void * 
[static]
 

Callback function for setting the current time point.

void SignContext::Start  ) 
 

void SignContext::UpdateProbes  ) 
 

This method updates all probes/needles with the latest OpenTracker data.

bool SignContext::Use3DTextures  )  [inline]
 

Returns if 3D textures are used.

void SignContext::Use3DTexturesOff  )  [inline]
 

Indicates that 2D textures should be used.

void SignContext::Use3DTexturesOn  )  [inline]
 

Indicates that 3D textures should be used.

SignContext::vtkTypeRevisionMacro SignContext  ,
vtkKWApplication 
 


Member Data Documentation

bool SignContext::annotation2D
 

controls the visibility of 2D annotations

bool SignContext::annotation3D
 

controls the visibility of 3D annotations

ColorNames SignContext::colors
 

static map of colors

std::string SignContext::currentFiducialVolumeID
 

Holds the ID of the volume that the current fiducials belong to (temporary).

bool SignContext::hasSplashScreen
 

flag that indicates if there is a splash screen

bool SignContext::hasStatusBar
 

flag that indicates if there is a status bar

bool SignContext::hasTransferFunction
 

Is true if there is any transfer function defined in the MRML tree.

ot::Context* SignContext::otc
 

RenderWindows SignContext::renderWindowsUpdate
 

vector that holds vtkRenderWindows that will be updated when doRender is set

SignStateManager* SignContext::StateManager
 

state manager object

bool SignContext::stopRendering
 

As long as this flag is true, render windows will not be updated.

int SignContext::timePoint
 

current timepoint for cine data

SignViewers SignContext::ViewerCollection
 

vector of viewers (Sign2DViewer or Sign3DViewer)


The documentation for this class was generated from the following files:
Generated on Mon Feb 26 12:13:01 2007 for TheSIGN by  doxygen 1.4.6