Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
mirtk::InterpolateImageFunction Class Referenceabstract

#include <InterpolateImageFunction.h>

Inheritance diagram for mirtk::InterpolateImageFunction:
Inheritance graph
Collaboration diagram for mirtk::InterpolateImageFunction:
Collaboration graph

Public Member Functions

const ImageAttributesAttributes () const
 Lattice attributes.
 
virtual void BoundingBox (double, double, int &, int &, int &, int &) const
 Returns discrete boundaries of local 2D image region needed for interpolation.
 
virtual void BoundingBox (double, double, double, int &, int &, int &, int &, int &, int &) const
 Returns discrete boundaries of local 3D image region needed for interpolation.
 
virtual void BoundingBox (double, double, double, double, int &, int &, int &, int &, int &, int &, int &, int &) const
 Returns discrete boundaries of local 4D image region needed for interpolation.
 
virtual void BoundingInterval (double, int &, int &) const =0
 
double Evaluate (double, double, double=0, double=0) const
 
double Evaluate (const Point &, double=0) const
 
double Evaluate (double, double, double=0, double=0)
 
void Evaluate (double *, double, double, double=0, int=1) const
 
void Evaluate (double *, const Point &, int=1) const
 
void Evaluate (Vector &, double, double, double=0, double=0) const
 
template<class TVoxel >
void Evaluate (GenericImage< TVoxel > &) const
 Evaluate image function at all locations of the output image.
 
virtual double EvaluateInside (double, double, double=0, double=0) const =0
 
virtual void EvaluateInside (double *, double, double, double=0, int=1) const
 
virtual void EvaluateInside (Vector &, double, double, double=0, double=0) const =0
 
void EvaluateJacobian (Matrix &, double, double, double=0, double=NaN) const
 
virtual void EvaluateJacobianInside (Matrix &, double, double, double=0, double=NaN) const
 
virtual void EvaluateJacobianOutside (Matrix &, double, double, double=0, double=NaN) const
 
void EvaluateJacobianWithPadding (Matrix &, double, double, double=0, double=NaN) const
 
virtual void EvaluateJacobianWithPaddingInside (Matrix &, double, double, double=0, double=NaN) const
 
virtual void EvaluateJacobianWithPaddingOutside (Matrix &, double, double, double=0, double=NaN) const
 
virtual double EvaluateOutside (double, double, double=0, double=0) const =0
 Evaluate scalar image at an arbitrary location (in pixels)
 
virtual void EvaluateOutside (double *, double, double, double=0, int=1) const
 Evaluate multi-channel image at an arbitrary location (in pixels)
 
virtual void EvaluateOutside (Vector &, double, double, double=0, double=0) const =0
 Evaluate vector image at an arbitrary location (in pixels)
 
double EvaluateWithPadding (double, double, double=0, double=0) const
 
void EvaluateWithPadding (double *, double, double, double=0, int=1) const
 
void EvaluateWithPadding (Vector &, double, double, double=0, double=0) const
 
virtual double EvaluateWithPaddingInside (double, double, double=0, double=0) const =0
 
virtual void EvaluateWithPaddingInside (double *, double, double, double=0, int=1) const
 
virtual void EvaluateWithPaddingInside (Vector &, double, double, double=0, double=0) const =0
 
virtual double EvaluateWithPaddingOutside (double, double, double=0, double=0) const =0
 
virtual void EvaluateWithPaddingOutside (double *, double, double, double=0, int=1) const
 
virtual void EvaluateWithPaddingOutside (Vector &, double, double, double=0, double=0) const =0
 
enum ExtrapolationMode ExtrapolationMode () const
 Get extrapolation mode used by this interpolator.
 
virtual void Extrapolator (ExtrapolateImageFunction *, bool=false)
 Set extrapolate image function for evaluation outside of image domain.
 
ExtrapolateImageFunctionExtrapolator ()
 
const ExtrapolateImageFunctionExtrapolator () const
 
void ImageToWorld (double &, double &) const
 Convert image location (in pixels) to world coordinates (in mm)
 
void ImageToWorld (double &, double &, double &) const
 Convert image location (in pixels) to world coordinates (in mm)
 
void ImageToWorld (Point &) const
 Convert image location (in pixels) to world coordinates (in mm)
 
void ImageToWorld (Vector3 &) const
 Convert image vector (in pixels) to world coordinates (in mm)
 
virtual void Initialize ()
 
virtual void Initialize (bool coeff)
 
void Input (const BaseImage *)
 Set input image.
 
const BaseImageInput () const
 Get input image.
 
void Inside (double &, double &, double &, double &) const
 
void Inside (double &, double &, double &, double &, double &, double &) const
 
void Inside (double &, double &, double &, double &, double &, double &, double &, double &) const
 
virtual enum InterpolationMode InterpolationMode () const =0
 Get interpolation mode corresponding to this interpolator.
 
bool IsForeground (double, double) const
 
bool IsForeground (double, double, double) const
 
bool IsForeground (double, double, double, double) const
 
bool IsForeground (const Point &) const
 
bool IsForeground (const Point &, double) const
 
bool IsInside (double, double) const
 
bool IsInside (double, double, double) const
 
bool IsInside (double, double, double, double) const
 
bool IsInside (const Point &) const
 
bool IsInside (const Point &, double) const
 
bool IsOutside (double, double) const
 
bool IsOutside (double, double, double) const
 
bool IsOutside (double, double, double, double) const
 
bool IsOutside (const Point &) const
 
bool IsOutside (const Point &, double) const
 
virtual ExtrapolateImageFunctionNew (enum ExtrapolationMode, const BaseImage *=NULL)
 Construct extrapolator which is compatible with this interpolator.
 
int T () const
 Image size along t axis.
 
double TSize () const
 Image spacing along t axis.
 
virtual void Update ()
 
void WorldToImage (double &, double &) const
 Convert world coordinates (in mm) to image location (in pixels)
 
void WorldToImage (double &, double &, double &) const
 Convert world coordinates (in mm) to image location (in pixels)
 
void WorldToImage (Point &) const
 Convert world coordinates (in mm) to image location (in pixels)
 
void WorldToImage (Vector3 &) const
 Convert world coordinates vector (in mm) to image vector (in pixels)
 
int X () const
 Image size along x axis.
 
double XSize () const
 Image spacing along x axis.
 
int Y () const
 Image size along y axis.
 
double YSize () const
 Image spacing along y axis.
 
int Z () const
 Image size along z axis.
 
double ZSize () const
 Image spacing along z axis.
 
virtual ~InterpolateImageFunction ()
 Destructor.
 
- Public Member Functions inherited from mirtk::ImageFunction
virtual ~ImageFunction ()
 Destructor.
 
- Public Member Functions inherited from mirtk::Object
virtual const char * NameOfClass () const =0
 Get name of class, which this object is an instance of.
 
virtual ParameterList Parameter () const
 Get parameter name/value pairs.
 
bool Parameter (const ParameterList &)
 Set parameters from name/value pairs.
 
virtual bool Set (const char *name, const char *value)
 
virtual ~Object ()
 Destructor.
 

Static Public Member Functions

static InterpolateImageFunctionNew (enum InterpolationMode=Interpolation_Default, const BaseImage *=NULL)
 Construct interpolator with default infinite extension of input image.
 
static InterpolateImageFunctionNew (enum InterpolationMode, enum ExtrapolationMode, const BaseImage *=NULL)
 
- Static Public Member Functions inherited from mirtk::Object
static const char * NameOfType ()
 Get name of this class type.
 

Protected Member Functions

 InterpolateImageFunction ()
 Default constructor.
 
- Protected Member Functions inherited from mirtk::ImageFunction
 ImageFunction ()
 Default constructor.
 
 ImageFunction (const ImageFunction &)
 Copy constructor.
 
- Protected Member Functions inherited from mirtk::Object
template<typename... Args>
void Throw (ErrorType err, const char *func, Args... args) const
 

Protected Attributes

ExtrapolateImageFunction_InfiniteInput
 
bool _InfiniteInputOwner
 Whether infinite discrete image was instantiated by this image function.
 
double _x1
 

Additional Inherited Members

- Static Protected Member Functions inherited from mirtk::Object
template<typename... Args>
static void ThrowStatic (ErrorType err, const char *cls, const char *func, Args... args)
 

Detailed Description

Abstract base class for any general image interpolation function

Definition at line 46 of file InterpolateImageFunction.h.

Member Function Documentation

§ BoundingInterval()

virtual void mirtk::InterpolateImageFunction::BoundingInterval ( double  ,
int &  ,
int &   
) const
pure virtual

§ Evaluate() [1/6]

double mirtk::InterpolateImageFunction::Evaluate ( double  x,
double  y,
double  z = 0,
double  t = 0 
) const
inlinevirtual

Evaluate scalar image at an arbitrary location (in pixels)

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateInside method is called. Otherwise, the EvaluateOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Implements mirtk::ImageFunction.

Definition at line 1144 of file InterpolateImageFunction.h.

§ Evaluate() [2/6]

double mirtk::InterpolateImageFunction::Evaluate ( const Point p,
double  t = 0 
) const
inline

Evaluate scalar image at an arbitrary location (in pixels)

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateInside method is called. Otherwise, the EvaluateOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Definition at line 1157 of file InterpolateImageFunction.h.

§ Evaluate() [3/6]

double mirtk::InterpolateImageFunction::Evaluate ( double  x,
double  y,
double  z = 0,
double  t = 0 
)
inline

Evaluate scalar image at an arbitrary location (in pixels)

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateInside method is called. Otherwise, the EvaluateOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Note
This overloaded function corrects for the const-ness of the corresponding virtual base class function ImageFunction::Evaluate.

Definition at line 1151 of file InterpolateImageFunction.h.

§ Evaluate() [4/6]

void mirtk::InterpolateImageFunction::Evaluate ( double *  v,
double  x,
double  y,
double  z = 0,
int  vt = 1 
) const
inline

Evaluate multi-channel image at an arbitrary location (in pixels)

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateInside method is called. Otherwise, the EvaluateOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Definition at line 1186 of file InterpolateImageFunction.h.

§ Evaluate() [5/6]

void mirtk::InterpolateImageFunction::Evaluate ( double *  v,
const Point p,
int  vt = 1 
) const
inline

Evaluate multi-channel image at an arbitrary location (in pixels)

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateInside method is called. Otherwise, the EvaluateOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Definition at line 1193 of file InterpolateImageFunction.h.

§ Evaluate() [6/6]

void mirtk::InterpolateImageFunction::Evaluate ( Vector v,
double  x,
double  y,
double  z = 0,
double  t = 0 
) const
inline

Evaluate vector image at an arbitrary location (in pixels)

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateInside method is called. Otherwise, the EvaluateOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Definition at line 1222 of file InterpolateImageFunction.h.

§ EvaluateInside() [1/3]

virtual double mirtk::InterpolateImageFunction::EvaluateInside ( double  ,
double  ,
double  = 0,
double  = 0 
) const
pure virtual

Evaluate scalar image without handling boundary conditions

This version is faster than EvaluateOutside, but is only defined inside the domain for which all image values required for interpolation are defined and thus require no extrapolation of the finite image.

Implemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, mirtk::GenericInterpolateImageFunction< BaseImage >, and mirtk::ShapeBasedInterpolateImageFunction.

§ EvaluateInside() [2/3]

void mirtk::InterpolateImageFunction::EvaluateInside ( double *  v,
double  x,
double  y,
double  z = 0,
int  vt = 1 
) const
inlinevirtual

Evaluate multi-channel image without handling boundary conditions

This version is faster than EvaluateOutside, but is only defined inside the domain for which all image values required for interpolation are defined and thus require no extrapolation of the finite image.

Reimplemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, and mirtk::GenericInterpolateImageFunction< BaseImage >.

Definition at line 1170 of file InterpolateImageFunction.h.

§ EvaluateInside() [3/3]

virtual void mirtk::InterpolateImageFunction::EvaluateInside ( Vector ,
double  ,
double  ,
double  = 0,
double  = 0 
) const
pure virtual

Evaluate vector image without handling boundary conditions

This version is faster than EvaluateOutside, but is only defined inside the domain for which all image values required for interpolation are defined and thus require no extrapolation of the finite image.

Implemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, mirtk::GenericInterpolateImageFunction< BaseImage >, and mirtk::ShapeBasedInterpolateImageFunction.

§ EvaluateJacobian()

void mirtk::InterpolateImageFunction::EvaluateJacobian ( Matrix jac,
double  x,
double  y,
double  z = 0,
double  t = NaN 
) const
inline

Get 1st order derivatives of given image at arbitrary location (in pixels)

When the image has scalar data type and stores vector components in the fourth dimension, the derivatives of all components are evaluated when the t coordinate is set to NaN. Otherwise, only the derivatives of the specified t component are evaluated.

Definition at line 1274 of file InterpolateImageFunction.h.

§ EvaluateJacobianInside()

void mirtk::InterpolateImageFunction::EvaluateJacobianInside ( Matrix ,
double  ,
double  ,
double  = 0,
double  = NaN 
) const
inlinevirtual

Get 1st order derivatives of given image at arbitrary location (in pixels)

When the image has scalar data type and stores vector components in the fourth dimension, the derivatives of all components are evaluated when the t coordinate is set to NaN. Otherwise, only the derivatives of the specified t component are evaluated.

Reimplemented in mirtk::GenericFastCubicBSplineInterpolateImageFunction< TImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< CPImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< BaseImage >, mirtk::GenericLinearInterpolateImageFunction< TImage >, mirtk::GenericLinearInterpolateImageFunction< ImageType >, mirtk::GenericLinearInterpolateImageFunction< CPImage >, and mirtk::GenericLinearInterpolateImageFunction< BaseImage >.

Definition at line 1260 of file InterpolateImageFunction.h.

§ EvaluateJacobianOutside()

void mirtk::InterpolateImageFunction::EvaluateJacobianOutside ( Matrix ,
double  ,
double  ,
double  = 0,
double  = NaN 
) const
inlinevirtual

Get 1st order derivatives of given image at arbitrary location (in pixels)

When the image has scalar data type and stores vector components in the fourth dimension, the derivatives of all components are evaluated when the t coordinate is set to NaN. Otherwise, only the derivatives of the specified t component are evaluated.

Reimplemented in mirtk::GenericFastCubicBSplineInterpolateImageFunction< TImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< CPImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< BaseImage >, mirtk::GenericLinearInterpolateImageFunction< TImage >, mirtk::GenericLinearInterpolateImageFunction< ImageType >, mirtk::GenericLinearInterpolateImageFunction< CPImage >, and mirtk::GenericLinearInterpolateImageFunction< BaseImage >.

Definition at line 1267 of file InterpolateImageFunction.h.

§ EvaluateJacobianWithPadding()

void mirtk::InterpolateImageFunction::EvaluateJacobianWithPadding ( Matrix jac,
double  x,
double  y,
double  z = 0,
double  t = NaN 
) const
inline

Get 1st order derivatives of given image at arbitrary location (in pixels)

When the image has scalar data type and stores vector components in the fourth dimension, the derivatives of all components are evaluated when the t coordinate is set to NaN. Otherwise, only the derivatives of the specified t component are evaluated.

Definition at line 1296 of file InterpolateImageFunction.h.

§ EvaluateJacobianWithPaddingInside()

void mirtk::InterpolateImageFunction::EvaluateJacobianWithPaddingInside ( Matrix ,
double  ,
double  ,
double  = 0,
double  = NaN 
) const
inlinevirtual

Get 1st order derivatives of given image at arbitrary location (in pixels)

When the image has scalar data type and stores vector components in the fourth dimension, the derivatives of all components are evaluated when the t coordinate is set to NaN. Otherwise, only the derivatives of the specified t component are evaluated.

Reimplemented in mirtk::GenericLinearInterpolateImageFunction< TImage >, mirtk::GenericLinearInterpolateImageFunction< ImageType >, mirtk::GenericLinearInterpolateImageFunction< CPImage >, and mirtk::GenericLinearInterpolateImageFunction< BaseImage >.

Definition at line 1282 of file InterpolateImageFunction.h.

§ EvaluateJacobianWithPaddingOutside()

void mirtk::InterpolateImageFunction::EvaluateJacobianWithPaddingOutside ( Matrix ,
double  ,
double  ,
double  = 0,
double  = NaN 
) const
inlinevirtual

Get 1st order derivatives of given image at arbitrary location (in pixels)

When the image has scalar data type and stores vector components in the fourth dimension, the derivatives of all components are evaluated when the t coordinate is set to NaN. Otherwise, only the derivatives of the specified t component are evaluated.

Reimplemented in mirtk::GenericLinearInterpolateImageFunction< TImage >, mirtk::GenericLinearInterpolateImageFunction< ImageType >, mirtk::GenericLinearInterpolateImageFunction< CPImage >, and mirtk::GenericLinearInterpolateImageFunction< BaseImage >.

Definition at line 1289 of file InterpolateImageFunction.h.

§ EvaluateWithPadding() [1/3]

double mirtk::InterpolateImageFunction::EvaluateWithPadding ( double  x,
double  y,
double  z = 0,
double  t = 0 
) const
inline

Evaluate scalar image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, the _DefaultValue is returned.

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateWithPaddingInside method is called. Otherwise, the EvaluateWithPaddingOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Definition at line 1163 of file InterpolateImageFunction.h.

§ EvaluateWithPadding() [2/3]

void mirtk::InterpolateImageFunction::EvaluateWithPadding ( double *  v,
double  x,
double  y,
double  z = 0,
int  vt = 1 
) const
inline

Evaluate multi-channel image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, the _DefaultValue is returned.

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateWithPaddingInside method is called. Otherwise, the EvaluateWithPaddingOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Definition at line 1215 of file InterpolateImageFunction.h.

§ EvaluateWithPadding() [3/3]

void mirtk::InterpolateImageFunction::EvaluateWithPadding ( Vector v,
double  x,
double  y,
double  z = 0,
double  t = 0 
) const
inline

Evaluate vector image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, a vector set to the _DefaultValue is returned.

If the location is inside the domain for which the filter can perform an interpolation without considering a particular boundary condition, the faster EvaluateWithPaddingInside method is called. Otherwise, the EvaluateWithPaddingOutside method which makes use of the extrapolation of the discrete image domain in order to interpolate also at boundary or outside locations is used.

Definition at line 1229 of file InterpolateImageFunction.h.

§ EvaluateWithPaddingInside() [1/3]

virtual double mirtk::InterpolateImageFunction::EvaluateWithPaddingInside ( double  ,
double  ,
double  = 0,
double  = 0 
) const
pure virtual

Evaluate scalar image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, the _DefaultValue is returned.

This version is faster than EvaluateWithPaddingOutside, but is only defined inside the domain for which all image values required for interpolation are defined and thus require no extrapolation of the finite image.

Implemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, mirtk::GenericInterpolateImageFunction< BaseImage >, and mirtk::ShapeBasedInterpolateImageFunction.

§ EvaluateWithPaddingInside() [2/3]

void mirtk::InterpolateImageFunction::EvaluateWithPaddingInside ( double *  v,
double  x,
double  y,
double  z = 0,
int  vt = 1 
) const
inlinevirtual

Evaluate multi-channel image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, the _DefaultValue is returned.

This version is faster than EvaluateWithPaddingOutside, but is only defined inside the domain for which all image values required for interpolation are defined and thus require no extrapolation of the finite image.

Reimplemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, and mirtk::GenericInterpolateImageFunction< BaseImage >.

Definition at line 1199 of file InterpolateImageFunction.h.

§ EvaluateWithPaddingInside() [3/3]

virtual void mirtk::InterpolateImageFunction::EvaluateWithPaddingInside ( Vector ,
double  ,
double  ,
double  = 0,
double  = 0 
) const
pure virtual

Evaluate vector image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, a vector set to the _DefaultValue is returned.

This version is faster than EvaluateWithPaddingOutside, but is only defined inside the domain for which all image values required for interpolation are defined and thus require no extrapolation of the finite image.

Implemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, mirtk::GenericInterpolateImageFunction< BaseImage >, and mirtk::ShapeBasedInterpolateImageFunction.

§ EvaluateWithPaddingOutside() [1/3]

virtual double mirtk::InterpolateImageFunction::EvaluateWithPaddingOutside ( double  ,
double  ,
double  = 0,
double  = 0 
) const
pure virtual

Evaluate scalar image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, the _DefaultValue is returned.

Implemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, mirtk::GenericInterpolateImageFunction< BaseImage >, and mirtk::ShapeBasedInterpolateImageFunction.

§ EvaluateWithPaddingOutside() [2/3]

void mirtk::InterpolateImageFunction::EvaluateWithPaddingOutside ( double *  v,
double  x,
double  y,
double  z = 0,
int  vt = 1 
) const
inlinevirtual

Evaluate multi-channel image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, the _DefaultValue is returned.

Reimplemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, and mirtk::GenericInterpolateImageFunction< BaseImage >.

Definition at line 1207 of file InterpolateImageFunction.h.

§ EvaluateWithPaddingOutside() [3/3]

virtual void mirtk::InterpolateImageFunction::EvaluateWithPaddingOutside ( Vector ,
double  ,
double  ,
double  = 0,
double  = 0 
) const
pure virtual

Evaluate vector image at an arbitrary location (in pixels)

If the location is partially inside the foreground region of the image, only the foreground values are interpolated. Otherwise, a vector set to the _DefaultValue is returned.

Implemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, mirtk::GenericInterpolateImageFunction< BaseImage >, and mirtk::ShapeBasedInterpolateImageFunction.

§ Extrapolator() [1/2]

ExtrapolateImageFunction * mirtk::InterpolateImageFunction::Extrapolator ( )
inline

Get extrapolate image function for evaluation outside of image domain or NULL if extrapolation mode is Extrapolation_None

Definition at line 844 of file InterpolateImageFunction.h.

§ Extrapolator() [2/2]

const ExtrapolateImageFunction * mirtk::InterpolateImageFunction::Extrapolator ( ) const
inline

Get extrapolate image function for evaluation outside of image domain or NULL if extrapolation mode is Extrapolation_None

Definition at line 850 of file InterpolateImageFunction.h.

§ Initialize() [1/2]

void mirtk::InterpolateImageFunction::Initialize ( )
inlinevirtual

Initialize image function

Note
Override the virtual Initialize(bool) member function in subclasses, but not this member function which is required by the abstract image function interface (irtkImageFunction::Initialize).

Reimplemented from mirtk::ImageFunction.

Definition at line 824 of file InterpolateImageFunction.h.

§ Initialize() [2/2]

virtual void mirtk::InterpolateImageFunction::Initialize ( bool  coeff)
virtual

Initialize image function

Parameters
[in]coeffWhether input image contains interpolation coefficients already. Otherwise, the interpolate image function will compute these coefficients from the input intensities.

Reimplemented in mirtk::GenericInterpolateImageFunction< TImage >, mirtk::GenericInterpolateImageFunction< ImageType >, mirtk::GenericInterpolateImageFunction< CPImage >, mirtk::GenericInterpolateImageFunction< BaseImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< TImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< CPImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< BaseImage >, mirtk::GenericCubicBSplineInterpolateImageFunction< TImage >, mirtk::GenericCubicBSplineInterpolateImageFunction< BaseImage >, mirtk::ShapeBasedInterpolateImageFunction, mirtk::GenericBSplineInterpolateImageFunction< TImage >, mirtk::GenericBSplineInterpolateImageFunction< BaseImage >, mirtk::GenericGaussianInterpolateImageFunction< TImage >, mirtk::GenericGaussianInterpolateImageFunction< BaseImage >, mirtk::GenericSincInterpolateImageFunction< TImage >, mirtk::GenericSincInterpolateImageFunction< BaseImage >, mirtk::GenericCSplineInterpolateImageFunction< TImage >, mirtk::GenericCSplineInterpolateImageFunction< BaseImage >, mirtk::GenericLinearInterpolateImageFunction< TImage >, mirtk::GenericLinearInterpolateImageFunction< ImageType >, mirtk::GenericLinearInterpolateImageFunction< CPImage >, and mirtk::GenericLinearInterpolateImageFunction< BaseImage >.

§ Inside() [1/3]

void mirtk::InterpolateImageFunction::Inside ( double &  x1,
double &  y1,
double &  x2,
double &  y2 
) const
inline

Returns the image domain for which this image interpolation function can be used without handling any form of boundary conditions

Definition at line 972 of file InterpolateImageFunction.h.

§ Inside() [2/3]

void mirtk::InterpolateImageFunction::Inside ( double &  x1,
double &  y1,
double &  z1,
double &  x2,
double &  y2,
double &  z2 
) const
inline

Returns the image domain for which this image interpolation function can be used without handling any form of boundary conditions

Definition at line 980 of file InterpolateImageFunction.h.

§ Inside() [3/3]

void mirtk::InterpolateImageFunction::Inside ( double &  x1,
double &  y1,
double &  z1,
double &  t1,
double &  x2,
double &  y2,
double &  z2,
double &  t2 
) const
inline

Returns the image domain for which this image interpolation function can be used without handling any form of boundary conditions

Definition at line 988 of file InterpolateImageFunction.h.

§ IsForeground() [1/5]

bool mirtk::InterpolateImageFunction::IsForeground ( double  x,
double  y 
) const
inline

Check if the location is fully inside the foreground of the image, i.e., including all discrete image locations required for interpolation

Definition at line 1104 of file InterpolateImageFunction.h.

§ IsForeground() [2/5]

bool mirtk::InterpolateImageFunction::IsForeground ( double  x,
double  y,
double  z 
) const
inline

Check if the location is fully inside the foreground of the image, i.e., including all discrete image locations required for interpolation

Definition at line 1112 of file InterpolateImageFunction.h.

§ IsForeground() [3/5]

bool mirtk::InterpolateImageFunction::IsForeground ( double  x,
double  y,
double  z,
double  t 
) const
inline

Check if the location is fully inside the foreground of the image, i.e., including all discrete image locations required for interpolation

Definition at line 1120 of file InterpolateImageFunction.h.

§ IsForeground() [4/5]

bool mirtk::InterpolateImageFunction::IsForeground ( const Point p) const
inline

Check if the location is fully inside the foreground of the image, i.e., including all discrete image locations required for interpolation

Definition at line 1128 of file InterpolateImageFunction.h.

§ IsForeground() [5/5]

bool mirtk::InterpolateImageFunction::IsForeground ( const Point p,
double  t 
) const
inline

Check if the location is fully inside the foreground of the image, i.e., including all discrete image locations required for interpolation

Definition at line 1134 of file InterpolateImageFunction.h.

§ IsInside() [1/5]

bool mirtk::InterpolateImageFunction::IsInside ( double  x,
double  y 
) const
inline

Check if the location (in pixels) is inside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1044 of file InterpolateImageFunction.h.

§ IsInside() [2/5]

bool mirtk::InterpolateImageFunction::IsInside ( double  x,
double  y,
double  z 
) const
inline

Check if the location (in pixels) is inside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1050 of file InterpolateImageFunction.h.

§ IsInside() [3/5]

bool mirtk::InterpolateImageFunction::IsInside ( double  x,
double  y,
double  z,
double  t 
) const
inline

Check if the location (in pixels) is inside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1056 of file InterpolateImageFunction.h.

§ IsInside() [4/5]

bool mirtk::InterpolateImageFunction::IsInside ( const Point p) const
inline

Check if the location (in pixels) is inside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1062 of file InterpolateImageFunction.h.

§ IsInside() [5/5]

bool mirtk::InterpolateImageFunction::IsInside ( const Point p,
double  t 
) const
inline

Check if the location (in pixels) is inside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1068 of file InterpolateImageFunction.h.

§ IsOutside() [1/5]

bool mirtk::InterpolateImageFunction::IsOutside ( double  x,
double  y 
) const
inline

Check if the location (in pixels) is outside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1074 of file InterpolateImageFunction.h.

§ IsOutside() [2/5]

bool mirtk::InterpolateImageFunction::IsOutside ( double  x,
double  y,
double  z 
) const
inline

Check if the location (in pixels) is outside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1080 of file InterpolateImageFunction.h.

§ IsOutside() [3/5]

bool mirtk::InterpolateImageFunction::IsOutside ( double  x,
double  y,
double  z,
double  t 
) const
inline

Check if the location (in pixels) is outside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1086 of file InterpolateImageFunction.h.

§ IsOutside() [4/5]

bool mirtk::InterpolateImageFunction::IsOutside ( const Point p) const
inline

Check if the location (in pixels) is outside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1092 of file InterpolateImageFunction.h.

§ IsOutside() [5/5]

bool mirtk::InterpolateImageFunction::IsOutside ( const Point p,
double  t 
) const
inline

Check if the location (in pixels) is outside the domain for which this image interpolation can be used without handling any form of boundary condition

Definition at line 1098 of file InterpolateImageFunction.h.

§ New()

static InterpolateImageFunction* mirtk::InterpolateImageFunction::New ( enum  InterpolationMode,
enum  ExtrapolationMode,
const BaseImage = NULL 
)
static

Construct interpolator with specified infinite extension of input image

The caller is required to set the input, initialize, and destroy the interpolator only, the extrapolator is initialized and destroyed by the interpolator unless the extrapolator has been replaced using the setter.

§ Update()

void mirtk::InterpolateImageFunction::Update ( )
inlinevirtual

Update internal state when input image content has changed

When the attributes of the input have changed, call Initialize instead. This function is used for example by B-spline based interpolation functions to re-compute the spline coefficients that interpolate the input image.

Reimplemented in mirtk::GenericFastCubicBSplineInterpolateImageFunction< TImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< CPImage >, mirtk::GenericFastCubicBSplineInterpolateImageFunction< BaseImage >, mirtk::GenericCubicBSplineInterpolateImageFunction< TImage >, mirtk::GenericCubicBSplineInterpolateImageFunction< BaseImage >, mirtk::GenericBSplineInterpolateImageFunction< TImage >, and mirtk::GenericBSplineInterpolateImageFunction< BaseImage >.

Definition at line 830 of file InterpolateImageFunction.h.

Member Data Documentation

§ _InfiniteInput

ExtrapolateImageFunction* mirtk::InterpolateImageFunction::_InfiniteInput
protected

Infinite discrete image obtained by extrapolation of finite input image. Unused by default, i.e., NULL which corresponds to extrapolation mode Extrapolation_None. If NULL, the interpolator has to deal with boundary cases itself either by only partially interpolating the available values or returning the _DefaultValue.

Definition at line 66 of file InterpolateImageFunction.h.

§ _x1

double mirtk::InterpolateImageFunction::_x1
protected

Domain of finite input image for which the interpolation is defined without requiring any extrapolation: [x1, x2]x[y1, y2]x[z1, z2]x[t1, t2]

Definition at line 73 of file InterpolateImageFunction.h.


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