Medical Imaging Interaction Toolkit  2022.04.99-b2814023
Medical Imaging Interaction Toolkit
mitk::NodePredicateGeometry Class Reference

Predicate that evaluates if the given DataNode's data object has the same geometry (in terms of spacing, origin, orientation) like the reference geometry. More...

#include <mitkNodePredicateGeometry.h>

Inheritance diagram for mitk::NodePredicateGeometry:
Collaboration diagram for mitk::NodePredicateGeometry:

Public Types

typedef NodePredicateGeometry Self
 
typedef NodePredicateBase Superclass
 
typedef itk::SmartPointer< SelfPointer
 
typedef itk::SmartPointer< const SelfConstPointer
 
- Public Types inherited from mitk::NodePredicateBase
typedef NodePredicateBase Self
 
typedef itk::Object 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 SetCheckPrecision (mitk::ScalarType precision)
 
virtual void SetCheckCoordinatePrecision (mitk::ScalarType _arg)
 
virtual mitk::ScalarType GetCheckCoordinatePrecision ()
 
virtual void SetCheckDirectionPrecision (mitk::ScalarType _arg)
 
virtual mitk::ScalarType GetCheckDirectionPrecision ()
 
 ~NodePredicateGeometry () override
 
bool CheckNode (const mitk::DataNode *node) const override
 This method will be used to evaluate the node. Has to be overwritten in subclasses. More...
 
- Public Member Functions inherited from mitk::NodePredicateBase
 ~NodePredicateBase () override
 Standard Destructor. More...
 

Static Public Member Functions

static const char * GetStaticNameOfClass ()
 
static Pointer New (const TimeGeometry *_arg)
 
static Pointer New (const BaseGeometry *_arg)
 
static Pointer New (const BaseGeometry *_arga, TimePointType _argb)
 
- Static Public Member Functions inherited from mitk::NodePredicateBase
static const char * GetStaticNameOfClass ()
 

Protected Member Functions

 NodePredicateGeometry (const BaseGeometry *refGeometry)
 
 NodePredicateGeometry (const BaseGeometry *refGeometry, TimePointType relevantTimePoint)
 
 NodePredicateGeometry (const TimeGeometry *refGeometry)
 

Protected Attributes

BaseGeometry::ConstPointer m_RefGeometry
 
TimeGeometry::ConstPointer m_RefTimeGeometry
 
TimePointType m_TimePoint
 
bool m_UseTimePoint
 
mitk::ScalarType m_CheckCoordinatePrecision
 
mitk::ScalarType m_CheckDirectionPrecision
 

Detailed Description

Predicate that evaluates if the given DataNode's data object has the same geometry (in terms of spacing, origin, orientation) like the reference geometry.

Documentation One can either check the whole time geometry of the date node by defining a referenc time geometry or check against one given reference base geometry. If the predicate should check against a base geometry, you can specify the timepoint of the data's time geometry that should be checked. If no timepoint is defined the predicate will evaluate the data geometry in the first timestep. Evaluates to "false" for unsupported or undefined data objects/geometries.

One can specify the tolerance/precision of the check via SetCheckPrecision(), SetCheckCoordinatePrecision() or SetCheckDirectionPrecision().

Remarks
The default tolerance for coordinate checks is defined by NODE_PREDICATE_GEOMETRY_DEFAULT_CHECK_COORDINATE_PRECISION. The default tolerance for direction checks is defined by NODE_PREDICATE_GEOMETRY_DEFAULT_CHECK_DIRECTION_PRECISION. Both are not as strict as mitk::eps. The reason is, that, for the typical use of the node predicate, mitk::eps would be to pedantic, as we encounter often rounding differences/errors in real world data sets. For more details, see the documentation of the aforementioned constants. We have introduced two different precision values because differences are less impactful for coordinates than for direction values. Therefore we can relax coordinate checks more then direction checks.

Definition at line 51 of file mitkNodePredicateGeometry.h.

Member Typedef Documentation

◆ ConstPointer

◆ Pointer

◆ Self

◆ Superclass

Constructor & Destructor Documentation

◆ ~NodePredicateGeometry()

mitk::NodePredicateGeometry::~NodePredicateGeometry ( )
override

◆ NodePredicateGeometry() [1/3]

mitk::NodePredicateGeometry::NodePredicateGeometry ( const BaseGeometry refGeometry)
protected

Constructor that is used configures the predicate to check the reference geometry against the first data timepoint.

◆ NodePredicateGeometry() [2/3]

mitk::NodePredicateGeometry::NodePredicateGeometry ( const BaseGeometry refGeometry,
TimePointType  relevantTimePoint 
)
protected

Constructor allows to define the timepoint that should be evaluated against the reference.

◆ NodePredicateGeometry() [3/3]

mitk::NodePredicateGeometry::NodePredicateGeometry ( const TimeGeometry refGeometry)
protected

Constructor that is used configures the predicate to check against the whole time geometry.

Member Function Documentation

◆ CheckNode()

bool mitk::NodePredicateGeometry::CheckNode ( const mitk::DataNode node) const
overridevirtual

This method will be used to evaluate the node. Has to be overwritten in subclasses.

Implements mitk::NodePredicateBase.

◆ GetCheckCoordinatePrecision()

virtual mitk::ScalarType mitk::NodePredicateGeometry::GetCheckCoordinatePrecision ( )
virtual

◆ GetCheckDirectionPrecision()

virtual mitk::ScalarType mitk::NodePredicateGeometry::GetCheckDirectionPrecision ( )
virtual

◆ GetClassHierarchy()

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

Reimplemented from mitk::NodePredicateBase.

Definition at line 54 of file mitkNodePredicateGeometry.h.

◆ GetClassName()

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

Reimplemented from mitk::NodePredicateBase.

◆ GetStaticNameOfClass()

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

Definition at line 54 of file mitkNodePredicateGeometry.h.

◆ New() [1/3]

static Pointer mitk::NodePredicateGeometry::New ( const TimeGeometry _arg)
inlinestatic

Definition at line 55 of file mitkNodePredicateGeometry.h.

◆ New() [2/3]

static Pointer mitk::NodePredicateGeometry::New ( const BaseGeometry _arg)
inlinestatic

Definition at line 56 of file mitkNodePredicateGeometry.h.

◆ New() [3/3]

static Pointer mitk::NodePredicateGeometry::New ( const BaseGeometry _arga,
TimePointType  _argb 
)
inlinestatic

Definition at line 57 of file mitkNodePredicateGeometry.h.

◆ SetCheckCoordinatePrecision()

virtual void mitk::NodePredicateGeometry::SetCheckCoordinatePrecision ( mitk::ScalarType  _arg)
virtual

◆ SetCheckDirectionPrecision()

virtual void mitk::NodePredicateGeometry::SetCheckDirectionPrecision ( mitk::ScalarType  _arg)
virtual

◆ SetCheckPrecision()

void mitk::NodePredicateGeometry::SetCheckPrecision ( mitk::ScalarType  precision)

Sets CheckCoordinatePrecision and CheckDirectionPrecision to the passed value.

Member Data Documentation

◆ m_CheckCoordinatePrecision

mitk::ScalarType mitk::NodePredicateGeometry::m_CheckCoordinatePrecision
protected

Precision that should be used for the equal coordinate checks.

Definition at line 87 of file mitkNodePredicateGeometry.h.

◆ m_CheckDirectionPrecision

mitk::ScalarType mitk::NodePredicateGeometry::m_CheckDirectionPrecision
protected

Precision that should be used for the equal direction checks.

Definition at line 89 of file mitkNodePredicateGeometry.h.

◆ m_RefGeometry

BaseGeometry::ConstPointer mitk::NodePredicateGeometry::m_RefGeometry
protected

Definition at line 81 of file mitkNodePredicateGeometry.h.

◆ m_RefTimeGeometry

TimeGeometry::ConstPointer mitk::NodePredicateGeometry::m_RefTimeGeometry
protected

Definition at line 82 of file mitkNodePredicateGeometry.h.

◆ m_TimePoint

TimePointType mitk::NodePredicateGeometry::m_TimePoint
protected

Definition at line 83 of file mitkNodePredicateGeometry.h.

◆ m_UseTimePoint

bool mitk::NodePredicateGeometry::m_UseTimePoint
protected

Indicates if m_TimePoint should be regarded or always the first timestep should be used.

Definition at line 85 of file mitkNodePredicateGeometry.h.


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