Medical Imaging Interaction Toolkit  2023.04.00
Medical Imaging Interaction Toolkit
mitk::NavigationDataRecorder Class Reference

This class records NavigationData objects into NavigationDataSets. More...

#include <mitkNavigationDataRecorder.h>

Inheritance diagram for mitk::NavigationDataRecorder:
Collaboration diagram for mitk::NavigationDataRecorder:

Public Member Functions

 mitkClassMacro (NavigationDataRecorder, NavigationDataToNavigationDataFilter)
 
Pointer Clone () const
 
virtual bool GetRecording ()
 Returns whether the NavigationDataRecorder is currently recording or not. More...
 
virtual mitk::NavigationDataSet::Pointer GetNavigationDataSet ()
 Returns the set that contains all of the recorded data. More...
 
virtual void SetRecordCountLimit (int _arg)
 Sets a limit of recorded data sets / frames. Recording will be stopped if the number is reached. values < 1 disable this behaviour. Default is -1. More...
 
virtual bool GetStandardizeTime ()
 Returns whether to use the navigationdata's time stamp or to create a new one upon recording. More...
 
virtual void SetStandardizeTime (bool _arg)
 If set to false, the navigationdata's timestamp will be used. If set to true, the recorder will generate a timestamp when it copies the data to the navigationdataset. More...
 
virtual void SetRecordOnlyValidData (bool _arg)
 If set to false, invalid navigationDatas will also be used. If set to true, the recorder will record only valid data. Standard is false. More...
 
virtual bool GetRecordOnlyValidData ()
 Returns whether to use valid data only. More...
 
virtual void StartRecording ()
 Starts recording NavigationData into the NavigationDataSet. More...
 
virtual void StopRecording ()
 Stops StopsRecording to the NavigationDataSet. More...
 
virtual void ResetRecording ()
 Resets the Datasets and the timestamp, so a new recording can happen. More...
 
virtual int GetNumberOfRecordedSteps ()
 Returns the number of time steps that were recorded in the current set. Warning: This Method does NOT Stop Recording! More...
 
- Public Member Functions inherited from mitk::NavigationDataToNavigationDataFilter
 mitkClassMacro (NavigationDataToNavigationDataFilter, NavigationDataSource)
 
virtual void SetInput (const NavigationData *nd)
 Set the input of this filter. More...
 
virtual void SetInput (unsigned int idx, const NavigationData *nd)
 Set input with id idx of this filter. More...
 
const NavigationDataGetInput (void) const
 Get the input of this filter. More...
 
const NavigationDataGetInput (unsigned int idx) const
 Get the input with id idx of this filter. More...
 
const NavigationDataGetInput (std::string navDataName) const
 Get the input with name navDataName of this filter. More...
 
DataObjectPointerArraySizeType GetInputIndex (std::string navDataName)
 return the index of the input with name navDataName, throw std::invalid_argument exception if that name was not found More...
 
virtual void ConnectTo (mitk::NavigationDataSource *UpstreamFilter)
 Connects the input of this filter to the outputs of the given NavigationDataSource. More...
 
- Public Member Functions inherited from mitk::NavigationDataSource
 mitkClassMacroItkParent (NavigationDataSource, itk::ProcessObject)
 
virtual std::string GetName ()
 
virtual void SetName (std::string _arg)
 Sets the human readable name of this source. There is also a default name, but you can use this method if you need to define it on your own. More...
 
NavigationDataGetOutput (void)
 return the output (output with id 0) of the filter More...
 
NavigationDataGetOutput (DataObjectPointerArraySizeType idx)
 return the output with id idx of the filter More...
 
NavigationDataGetOutput (const std::string &navDataName)
 return the output with name navDataName of the filter More...
 
NavigationTool::Pointer GetToolMetaData (DataObjectPointerArraySizeType idx)
 
NavigationTool::Pointer GetToolMetaData (const std::string &navDataName)
 
virtual mitk::NavigationToolStorage::Pointer GetToolMetaDataCollection ()
 
virtual void SetToolMetaDataCollection (mitk::NavigationToolStorage::Pointer _arg)
 
DataObjectPointerArraySizeType GetOutputIndex (std::string navDataName)
 return the index of the output with name navDataName, -1 if no output with that name was found More...
 
virtual void RegisterAsMicroservice ()
 Registers this object as a Microservice, making it available to every module and/or plugin. To unregister, call UnregisterMicroservice(). More...
 
virtual void UnRegisterMicroservice ()
 Registers this object as a Microservice, making it available to every module and/or plugin. More...
 
std::string GetMicroserviceID ()
 Returns the id that this device is registered with. The id will only be valid, if the NavigationDataSource has been registered using RegisterAsMicroservice(). More...
 
virtual void GraftNthOutput (unsigned int idx, itk::DataObject *graft)
 Graft the specified DataObject onto this ProcessObject's output. More...
 
virtual void GraftOutput (itk::DataObject *graft)
 Graft the specified DataObject onto this ProcessObject's output. More...
 
itk::DataObject::Pointer MakeOutput (DataObjectPointerArraySizeType idx) override
 
itk::DataObject::Pointer MakeOutput (const DataObjectIdentifierType &name) override
 
virtual void SetParameters (const mitk::PropertyList *)
 Set all filter parameters as the PropertyList p. More...
 
virtual mitk::PropertyList::ConstPointer GetParameters () const
 Get all filter parameters as a PropertyList. More...
 
virtual void Freeze ()
 
virtual void UnFreeze ()
 
virtual bool GetIsFrozen ()
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

void GenerateData () override
 
 NavigationDataRecorder ()
 
 ~NavigationDataRecorder () override
 
- Protected Member Functions inherited from mitk::NavigationDataToNavigationDataFilter
 NavigationDataToNavigationDataFilter ()
 
 ~NavigationDataToNavigationDataFilter () override
 
void CreateOutputsForAllInputs ()
 Create an output for each input. More...
 
- Protected Member Functions inherited from mitk::NavigationDataSource
 NavigationDataSource ()
 
 ~NavigationDataSource () override
 

Protected Attributes

unsigned int m_NumberOfInputs
 counts the numbers of added input NavigationDatas More...
 
mitk::NavigationDataSet::Pointer m_NavigationDataSet
 
bool m_Recording
 indicates whether the recording is started or not More...
 
bool m_StandardizeTime
 indicates whether one should use the timestamps in NavigationData or create new timestamps upon recording More...
 
bool m_StandardizedTimeInitialized
 set to true the first time start recording is called. More...
 
int m_RecordCountLimit
 limits the number of frames, recording will be stopped if the limit is reached. -1 disables the limit More...
 
bool m_RecordOnlyValidData
 indicates whether only valid data is recorded More...
 
- Protected Attributes inherited from mitk::NavigationDataSource
std::string m_Name
 
bool m_IsFrozen
 
NavigationToolStorage::Pointer m_ToolMetaDataCollection
 

Additional Inherited Members

- Static Public Attributes inherited from mitk::NavigationDataSource
static const std::string US_INTERFACE_NAME
 These Constants are used in conjunction with Microservices. More...
 
static const std::string US_PROPKEY_DEVICENAME
 
static const std::string US_PROPKEY_ID
 
static const std::string US_PROPKEY_ISACTIVE
 

Detailed Description

This class records NavigationData objects into NavigationDataSets.

Documentation The recording is started with the call of the method StartRecording(). Now every Update() stores the current state of the added NavigationDatas into the NavigationDataSet. With StopRecording() the stream is stopped, but can be resumed anytime. To start recording to a new NavigationDataSet, call ResetRecording();

Warning
Do not add inputs while the recorder ist recording. The recorder can't handle that and will cause a nullpointer exception.

Definition at line 34 of file mitkNavigationDataRecorder.h.

Constructor & Destructor Documentation

◆ NavigationDataRecorder()

mitk::NavigationDataRecorder::NavigationDataRecorder ( )
protected

◆ ~NavigationDataRecorder()

mitk::NavigationDataRecorder::~NavigationDataRecorder ( )
overrideprotected

Member Function Documentation

◆ Clone()

Pointer mitk::NavigationDataRecorder::Clone ( ) const

◆ GenerateData()

void mitk::NavigationDataRecorder::GenerateData ( )
overrideprotected

◆ GetNavigationDataSet()

virtual mitk::NavigationDataSet::Pointer mitk::NavigationDataRecorder::GetNavigationDataSet ( )
virtual

Returns the set that contains all of the recorded data.

◆ GetNumberOfRecordedSteps()

virtual int mitk::NavigationDataRecorder::GetNumberOfRecordedSteps ( )
virtual

Returns the number of time steps that were recorded in the current set. Warning: This Method does NOT Stop Recording!

◆ GetRecording()

virtual bool mitk::NavigationDataRecorder::GetRecording ( )
virtual

Returns whether the NavigationDataRecorder is currently recording or not.

◆ GetRecordOnlyValidData()

virtual bool mitk::NavigationDataRecorder::GetRecordOnlyValidData ( )
virtual

Returns whether to use valid data only.

◆ GetStandardizeTime()

virtual bool mitk::NavigationDataRecorder::GetStandardizeTime ( )
virtual

Returns whether to use the navigationdata's time stamp or to create a new one upon recording.

◆ mitkClassMacro()

mitk::NavigationDataRecorder::mitkClassMacro ( NavigationDataRecorder  ,
NavigationDataToNavigationDataFilter   
)

◆ New()

static Pointer mitk::NavigationDataRecorder::New ( )
static

◆ ResetRecording()

virtual void mitk::NavigationDataRecorder::ResetRecording ( )
virtual

Resets the Datasets and the timestamp, so a new recording can happen.

Do not forget to save the old Dataset, it will be lost after calling this function.

◆ SetRecordCountLimit()

virtual void mitk::NavigationDataRecorder::SetRecordCountLimit ( int  _arg)
virtual

Sets a limit of recorded data sets / frames. Recording will be stopped if the number is reached. values < 1 disable this behaviour. Default is -1.

◆ SetRecordOnlyValidData()

virtual void mitk::NavigationDataRecorder::SetRecordOnlyValidData ( bool  _arg)
virtual

If set to false, invalid navigationDatas will also be used. If set to true, the recorder will record only valid data. Standard is false.

◆ SetStandardizeTime()

virtual void mitk::NavigationDataRecorder::SetStandardizeTime ( bool  _arg)
virtual

If set to false, the navigationdata's timestamp will be used. If set to true, the recorder will generate a timestamp when it copies the data to the navigationdataset.

◆ StartRecording()

virtual void mitk::NavigationDataRecorder::StartRecording ( )
virtual

Starts recording NavigationData into the NavigationDataSet.

◆ StopRecording()

virtual void mitk::NavigationDataRecorder::StopRecording ( )
virtual

Stops StopsRecording to the NavigationDataSet.

Recording can be resumed to the same Dataset by just calling StartRecording() again. Call ResetRecording() to start recording to a new Dataset;

Member Data Documentation

◆ m_NavigationDataSet

mitk::NavigationDataSet::Pointer mitk::NavigationDataRecorder::m_NavigationDataSet
protected

Definition at line 117 of file mitkNavigationDataRecorder.h.

◆ m_NumberOfInputs

unsigned int mitk::NavigationDataRecorder::m_NumberOfInputs
protected

counts the numbers of added input NavigationDatas

Definition at line 115 of file mitkNavigationDataRecorder.h.

◆ m_RecordCountLimit

int mitk::NavigationDataRecorder::m_RecordCountLimit
protected

limits the number of frames, recording will be stopped if the limit is reached. -1 disables the limit

Definition at line 125 of file mitkNavigationDataRecorder.h.

◆ m_Recording

bool mitk::NavigationDataRecorder::m_Recording
protected

indicates whether the recording is started or not

Definition at line 119 of file mitkNavigationDataRecorder.h.

◆ m_RecordOnlyValidData

bool mitk::NavigationDataRecorder::m_RecordOnlyValidData
protected

indicates whether only valid data is recorded

Definition at line 127 of file mitkNavigationDataRecorder.h.

◆ m_StandardizedTimeInitialized

bool mitk::NavigationDataRecorder::m_StandardizedTimeInitialized
protected

set to true the first time start recording is called.

Definition at line 123 of file mitkNavigationDataRecorder.h.

◆ m_StandardizeTime

bool mitk::NavigationDataRecorder::m_StandardizeTime
protected

indicates whether one should use the timestamps in NavigationData or create new timestamps upon recording

Definition at line 121 of file mitkNavigationDataRecorder.h.


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