43 if (timePoint > std::numeric_limits<TimePointType>().
max())
44 timePoint = std::numeric_limits<TimePointType>().
max();
67 if (timePoint > std::numeric_limits<TimePointType>().
max())
68 timePoint = std::numeric_limits<TimePointType>().
max();
75 if (timePoint > std::numeric_limits<TimePointType>().max())
76 timePoint = std::numeric_limits<TimePointType>().max();
100 if (
m_FirstTimePoint <= itk::NumericTraits<TimePointType>::NonpositiveMin() ||
207 newTimeGeometry->m_GeometryVector.clear();
212 newTimeGeometry->SetTimeStepGeometry(tempGeometry, i);
228 timeSteps = (timeSteps > 0) ? timeSteps : 1;
234 m_StepDuration = std::numeric_limits<mitk::TimePointType>().infinity();
240 for (
TimeStepType currentStep = 0; currentStep < timeSteps; ++currentStep)
248 MITK_INFO <<
"Cloning of geometry produced an error!";
257 geometry->Initialize();
259 this->
Initialize(geometry.GetPointer(), timeSteps);
264 os << indent <<
" TimeSteps: " << this->
CountTimeSteps() << std::endl;
266 os << indent <<
" StepDuration: " << this->
GetStepDuration() <<
" ms" << std::endl;
270 os << indent <<
" GetGeometryForTimeStep(0): ";
272 os <<
"nullptr" << std::endl;
283 static_cast<const TimeGeometry &>(leftHandSide), static_cast<const TimeGeometry &>(rightHandSide), eps, verbose);
TimeStepType CountTimeSteps() const override
Returns the number of time steps.
itk::FixedArray< ScalarType, 2 > TimeBounds
Standard typedef for time-bounds.
void PrintSelf(std::ostream &os, itk::Indent indent) const override
BaseGeometry::Pointer GetGeometryForTimeStep(TimeStepType timeStep) const override
Returns the geometry which corresponds to the given time step.
ProportionalTimeGeometry()
TimePointType GetMaximumTimePoint() const override
Returns the last time point for which the object is valid.
void ClearAllGeometries()
BaseGeometry::Pointer GetGeometryCloneForTimeStep(TimeStepType timeStep) const override
Returns the geometry which corresponds to the given time step.
void ReserveSpaceForGeometries(TimeStepType numberOfGeometries)
itk::LightObject::Pointer InternalClone() const override
Makes a deep copy of the current object.
BaseGeometry::Pointer GetGeometryForTimePoint(TimePointType timePoint) const override
Returns the geometry which corresponds to the given time point.
void ReplaceTimeStepGeometries(const BaseGeometry *geometry) override
Replaces the geometry instances with clones of the passed geometry.
bool IsValidTimeStep(TimeStepType timeStep) const override
Test for the given time step if a geometry is availible.
TimeBounds GetTimeBounds() const override
Get the time bounds (in ms)
static void clone(T *&dst, S *src, int n)
void Expand(TimeStepType size) override
Expands the time geometry to the given number of time steps.
void SetTimeStepGeometry(BaseGeometry *geometry, TimeStepType timeStep) override
Sets the geometry for the given time step.
virtual TimePointType GetStepDuration() const
bool IsValidTimePoint(TimePointType timePoint) const override
Tests if a given time point is covered by this object.
TimePointType GetMinimumTimePoint() const override
Returns the first time point for which the object is valid.
mitk::ScalarType TimePointType
std::vcl_size_t TimeStepType
bool IsValid() const override
Tests if all necessary informations are set and the object is valid.
TimePointType TimeStepToTimePoint(TimeStepType timeStep) const override
Converts a time step to a time point.
TimePointType m_FirstTimePoint
TimePointType m_StepDuration
~ProportionalTimeGeometry() override
MITKNEWMODULE_EXPORT bool Equal(mitk::ExampleDataStructure *leftHandSide, mitk::ExampleDataStructure *rightHandSide, mitk::ScalarType eps, bool verbose)
Returns true if the example data structures are considered equal.
virtual TimePointType GetFirstTimePoint() const
MITKCORE_EXPORT const ScalarType eps
TimeStepType TimePointToTimeStep(TimePointType timePoint) const override
Converts a time point to the corresponding time step.
LightObject::Pointer InternalClone() const override
Makes a deep copy of the current object.
void Update()
Updates the geometry.
void Initialize() override
Initilizes a new object with one time steps which contains an empty geometry.
BaseGeometry Describes the geometry of a data object.
std::vector< BaseGeometry::Pointer > m_GeometryVector