20 #ifndef MIRTK_BSplineInterpolateImageFunction4D_HXX 21 #define MIRTK_BSplineInterpolateImageFunction4D_HXX 23 #include "mirtk/BSplineInterpolateImageFunction4D.h" 24 #include "mirtk/BSplineInterpolateImageFunction.hxx" 31 template <
class TImage>
35 this->NumberOfDimensions(4);
39 template <
class TImage>
40 inline typename GenericBSplineInterpolateImageFunction4D<TImage>::VoxelType
42 ::Get(
double x,
double y,
double z,
double t)
const 44 return this->Get4D(x, y, z, t);
48 template <
class TImage>
49 inline typename GenericBSplineInterpolateImageFunction4D<TImage>::VoxelType
53 return this->GetWithPadding4D(x, y, z, t);
57 template <
class TImage>
template <
class TOtherImage>
58 inline typename TOtherImage::VoxelType
60 ::Get(
const TOtherImage *coeff,
double x,
double y,
double z,
double t)
const 62 return this->Get4D(coeff, x, y, z, t);
66 template <
class TImage>
template <
class TOtherImage,
class TCoefficient>
67 inline typename TCoefficient::VoxelType
70 double x,
double y,
double z,
double t)
const 72 return this->GetWithPadding4D(input, coeff, x, y, z, t);
76 template <
class TImage>
77 inline typename GenericBSplineInterpolateImageFunction4D<TImage>::VoxelType
81 return voxel_cast<VoxelType>(
Get(&this->_Coefficient, x, y, z, t));
85 template <
class TImage>
86 inline typename GenericBSplineInterpolateImageFunction4D<TImage>::VoxelType
90 if (this->_InfiniteCoefficient) {
91 return voxel_cast<VoxelType>(
Get(this->_InfiniteCoefficient, x, y, z, t));
93 return Get(x, y, z, t);
98 template <
class TImage>
99 inline typename GenericBSplineInterpolateImageFunction4D<TImage>::VoxelType
103 return voxel_cast<VoxelType>(GetWithPadding(this->Input(), &this->_Coefficient, x, y, z, t));
107 template <
class TImage>
108 inline typename GenericBSplineInterpolateImageFunction4D<TImage>::VoxelType
112 if (this->Extrapolator() && this->_InfiniteCoefficient) {
113 return voxel_cast<VoxelType>(GetWithPadding(this->Extrapolator(), this->_InfiniteCoefficient, x, y, z, t));
115 return GetWithPadding(x, y, z, t);
122 #endif // MIRTK_BSplineInterpolateImageFunction4D_HXX string Get(const ParameterList ¶ms, string name)
Get parameter value from parameters list.
GenericBSplineInterpolateImageFunction4D()
Default constructor.
virtual VoxelType GetOutside(double, double, double, double) const
Evaluate generic image at an arbitrary location (in pixels)
VoxelType GetWithPadding(double, double, double, double) const
virtual VoxelType GetWithPaddingInside(double, double, double, double) const
virtual VoxelType GetInside(double, double, double, double) const
VoxelType Get(double, double, double, double) const
virtual VoxelType GetWithPaddingOutside(double, double, double, double) const