Medical Imaging Interaction Toolkit  2023.12.00
Medical Imaging Interaction Toolkit
mitk::TimeNavigationController Class Reference

Controls the time-related properties of the time stepper, according to the given input world time geomtry. More...

#include <mitkTimeNavigationController.h>

Inheritance diagram for mitk::TimeNavigationController:
Collaboration diagram for mitk::TimeNavigationController:

Classes

class  TimeEvent
 

Public Types

typedef TimeNavigationController Self
 
typedef BaseController Superclass
 
typedef itk::SmartPointer< SelfPointer
 
typedef itk::SmartPointer< const SelfConstPointer
 
- Public Types inherited from mitk::BaseController
typedef BaseController Self
 
typedef OperationActor Superclass
 
typedef itk::SmartPointer< SelfPointer
 
typedef itk::SmartPointer< const SelfConstPointer
 

Public Member Functions

virtual std::vector< std::string > GetClassHierarchy () const override
 
virtual const char * GetClassName () const
 
void SetInputWorldTimeGeometry (const TimeGeometry *geometry)
 Set the input time geometry out of which the time-related properties will be generated. More...
 
virtual const mitk::TimeGeometryGetInputWorldTimeGeometry ()
 
virtual void Update ()
 Do the actual time-related properties extraction and send the currently selected time step to the connecte observers (renderers). More...
 
virtual void SendTime ()
 Send the currently selected time step to the connected observers (renderers). More...
 
template<typename T >
void ConnectTimeEvent (T *receiver)
 
template<typename T >
void Disconnect (T *receiver)
 
TimeStepType GetSelectedTimeStep () const
 Convenience method that returns the time step currently selected by the controller. More...
 
TimePointType GetSelectedTimePoint () const
 Convenience method that returns the time point that corresponds to the selected time step. The conversion is done using the time geometry of the controller. If the time geometry is not yet set, this function will always return 0.0. More...
 
- Public Member Functions inherited from mitk::BaseController
StepperGetStepper ()
 Get the stepper through the corresponding dimension. More...
 
const StepperGetStepper () const
 
- Public Member Functions inherited from mitk::OperationActor
 itkTypeMacroNoParent (OperationActor) virtual ~OperationActor()
 

Static Public Member Functions

static const char * GetStaticNameOfClass ()
 
static Pointer New ()
 
- Static Public Member Functions inherited from mitk::BaseController
static const char * GetStaticNameOfClass ()
 
static Pointer New ()
 

Protected Types

typedef std::map< void *, std::list< unsigned long > > ObserverTagsMapType
 

Protected Member Functions

 TimeNavigationController ()
 
 ~TimeNavigationController () override
 
- Protected Member Functions inherited from mitk::BaseController
 BaseController ()
 Default Constructor. More...
 
 ~BaseController () override
 Default Destructor. More...
 
void ExecuteOperation (Operation *) override
 

Protected Attributes

TimeGeometry::ConstPointer m_InputWorldTimeGeometry
 
bool m_BlockUpdate
 
ObserverTagsMapType m_ReceiverToObserverTagsMap
 
- Protected Attributes inherited from mitk::BaseController
Stepper::Pointer m_Stepper
 
unsigned long m_LastUpdateTime
 

Detailed Description

Controls the time-related properties of the time stepper, according to the given input world time geomtry.

A TimeNavigationController takes a TimeGeometry as input world time geometry and sets the properties of the associated stepper (BaseController). The time-related properties are:

  • steps: the number of input time steps
  • pos: the current time step / position of the stepper
  • range: the time bounds for the slider (minimum, maximum)

The timestep controls the selection of a specific time point from the TimeGeometry. The TimeNavigationController generates ITK events to tell observers, like a BaseRenderer, when the selected timestep changes.

Example:

// Initialize the time navigation controller.
// Set the required input world time geomtry (a TimeGeometry::ConstPointer).
timeCtrl->SetInputWorldTimeGeometry(geometry.GetPointer());
// Set the time-related properties and send the information to the connected renderer(s).
timeCtrl->Update();

Vvisible navigation widgets can be connected to a TimeNavigationController, e.g., a QmitkSliceNavigationWidget (for Qt):

// Create the visible navigation widget (a slider with a spin-box).
// Connect the navigation widget to the time-stepper of the
// TimeNavigationController. For initialization (timestep, minimal and
// maximal values) the values of the TimeNavigationController are used.
// Thus, accessing methods of a navigation widget is normally not necessary,
// since everything can be set via the (Qt-independent) TimeNavigationController.
// The QmitkStepperAdapter converts the Qt-signals to Qt-independent
// itk-events.
new QmitkStepperAdapter(navigationWidget, timeCtrl->GetStepper());

Definition at line 69 of file mitkTimeNavigationController.h.

Member Typedef Documentation

◆ ConstPointer

◆ ObserverTagsMapType

typedef std::map<void*, std::list<unsigned long> > mitk::TimeNavigationController::ObserverTagsMapType
protected

Definition at line 166 of file mitkTimeNavigationController.h.

◆ Pointer

◆ Self

◆ Superclass

Constructor & Destructor Documentation

◆ TimeNavigationController()

mitk::TimeNavigationController::TimeNavigationController ( )
protected

◆ ~TimeNavigationController()

mitk::TimeNavigationController::~TimeNavigationController ( )
overrideprotected

Member Function Documentation

◆ ConnectTimeEvent()

template<typename T >
void mitk::TimeNavigationController::ConnectTimeEvent ( T *  receiver)
inline

Definition at line 121 of file mitkTimeNavigationController.h.

◆ Disconnect()

template<typename T >
void mitk::TimeNavigationController::Disconnect ( T *  receiver)
inline

Definition at line 132 of file mitkTimeNavigationController.h.

◆ GetClassHierarchy()

virtual std::vector<std::string> mitk::TimeNavigationController::GetClassHierarchy ( ) const
inlineoverridevirtual

Reimplemented from mitk::BaseController.

Definition at line 73 of file mitkTimeNavigationController.h.

◆ GetClassName()

virtual const char* mitk::TimeNavigationController::GetClassName ( ) const
virtual

Reimplemented from mitk::BaseController.

◆ GetInputWorldTimeGeometry()

virtual const mitk::TimeGeometry* mitk::TimeNavigationController::GetInputWorldTimeGeometry ( )
virtual

◆ GetSelectedTimePoint()

TimePointType mitk::TimeNavigationController::GetSelectedTimePoint ( ) const

Convenience method that returns the time point that corresponds to the selected time step. The conversion is done using the time geometry of the controller. If the time geometry is not yet set, this function will always return 0.0.

◆ GetSelectedTimeStep()

TimeStepType mitk::TimeNavigationController::GetSelectedTimeStep ( ) const

Convenience method that returns the time step currently selected by the controller.

◆ GetStaticNameOfClass()

static const char* mitk::TimeNavigationController::GetStaticNameOfClass ( )
inlinestatic

Definition at line 73 of file mitkTimeNavigationController.h.

◆ New()

static Pointer mitk::TimeNavigationController::New ( )
static

◆ SendTime()

virtual void mitk::TimeNavigationController::SendTime ( )
virtual

Send the currently selected time step to the connected observers (renderers).

Called by Update().

◆ SetInputWorldTimeGeometry()

void mitk::TimeNavigationController::SetInputWorldTimeGeometry ( const TimeGeometry geometry)

Set the input time geometry out of which the time-related properties will be generated.

Any previous set input geometry (3D or Time) will be ignored in the future.

◆ Update()

virtual void mitk::TimeNavigationController::Update ( )
virtual

Do the actual time-related properties extraction and send the currently selected time step to the connecte observers (renderers).

Member Data Documentation

◆ m_BlockUpdate

bool mitk::TimeNavigationController::m_BlockUpdate
protected

Definition at line 164 of file mitkTimeNavigationController.h.

◆ m_InputWorldTimeGeometry

TimeGeometry::ConstPointer mitk::TimeNavigationController::m_InputWorldTimeGeometry
protected

Definition at line 162 of file mitkTimeNavigationController.h.

◆ m_ReceiverToObserverTagsMap

ObserverTagsMapType mitk::TimeNavigationController::m_ReceiverToObserverTagsMap
protected

Definition at line 167 of file mitkTimeNavigationController.h.


The documentation for this class was generated from the following file:
mitk::TimeNavigationController::New
static Pointer New()
QmitkStepperAdapter
Helper class to connect Qt-based navigators to instances of Stepper.
Definition: QmitkStepperAdapter.h:32
QmitkSliceNavigationWidget
Definition: QmitkSliceNavigationWidget.h:24