21 #ifndef vtkAbstractImageInterpolator_h
22 #define vtkAbstractImageInterpolator_h
24 #include "vtkImagingCoreModule.h"
34 VTK_ABI_NAMESPACE_BEGIN
55 virtual void ReleaseData();
68 virtual void Update();
77 double Interpolate(
double x,
double y,
double z,
int component);
86 bool Interpolate(
const double point[3],
double*
value);
91 void SetOutValue(
double outValue);
99 void SetTolerance(
double tol);
108 void SetComponentOffset(
int offset);
117 void SetComponentCount(
int count);
124 int ComputeNumberOfComponents(
int inputComponents);
131 int GetNumberOfComponents();
139 void InterpolateIJK(
const double point[3],
double*
value);
140 void InterpolateIJK(
const float point[3],
float*
value);
150 bool CheckBoundsIJK(
const double x[3]);
151 bool CheckBoundsIJK(
const float x[3]);
167 const char* GetBorderModeAsString();
177 void SetSlidingWindow(
bool x);
188 virtual void ComputeSupportSize(
const double matrix[16],
int support[3]) = 0;
196 virtual bool IsSeparable() = 0;
209 virtual void PrecomputeWeightsForExtent(
const double matrix[16],
const int extent[6],
211 virtual void PrecomputeWeightsForExtent(
const float matrix[16],
const int extent[6],
237 vtkGetVector3Macro(Spacing,
double);
244 vtkGetVectorMacro(Direction,
double, 9);
251 vtkGetVector3Macro(Origin,
double);
258 vtkGetVector6Macro(Extent,
int);
268 virtual void InternalUpdate() = 0;
278 void CoordinateToIJK(
const double point[3],
double ijk[3]);
284 virtual void GetInterpolationFunc(
286 virtual void GetInterpolationFunc(
294 virtual void GetRowInterpolationFunc(
296 virtual void GetRowInterpolationFunc(
304 virtual void GetSlidingWindowFunc(
306 virtual void GetSlidingWindowFunc(
311 double StructuredBoundsDouble[6];
312 float StructuredBoundsFloat[6];
316 double InverseDirection[9];
329 void (*InterpolationFuncDouble)(
333 void (*RowInterpolationFuncDouble)(
335 void (*RowInterpolationFuncFloat)(
356 return !((x[0] < bounds[0]) || (x[0] > bounds[1]) || (x[1] < bounds[2]) || (x[1] > bounds[3]) ||
357 (x[2] < bounds[4]) || (x[2] > bounds[5]));
363 return !((x[0] < bounds[0]) || (x[0] > bounds[1]) || (x[1] < bounds[2]) || (x[1] > bounds[3]) ||
364 (x[2] < bounds[4]) || (x[2] > bounds[5]));
379 VTK_ABI_NAMESPACE_END
interpolate data values from images
abstract base class for most VTK objects
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetBorderModeToRepeat()
The border mode (default: clamp).
void InterpolateIJK(const double point[3], double *value)
A version of Interpolate that takes structured coords instead of data coords.
vtkInterpolationInfo * InterpolationInfo
a simple class to control print indentation
topologically and geometrically regular array of data
float StructuredBoundsFloat[6]
vtkImageBorderMode BorderMode
abstract superclass for arrays of numeric data
vtkImageBorderMode GetBorderMode()
The border mode (default: clamp).
void(* InterpolationFuncFloat)(vtkInterpolationInfo *info, const float point[3], float *outPtr)
void(* RowInterpolationFuncDouble)(vtkInterpolationWeights *weights, int idX, int idY, int idZ, double *outPtr, int n)
double StructuredBoundsDouble[6]
bool CheckBoundsIJK(const double x[3])
Check an x,y,z point to see if it is within the bounds for the structured coords of the image...
void(* RowInterpolationFuncFloat)(vtkInterpolationWeights *weights, int idX, int idY, int idZ, float *outPtr, int n)
general representation of visualization data
void SetBorderModeToClamp()
The border mode (default: clamp).
void InterpolateRow(vtkInterpolationWeights *&weights, int xIdx, int yIdx, int zIdx, double *value, int n)
Get a row of samples, using the weights that were precomputed by PrecomputeWeightsForExtent.
void(* InterpolationFuncDouble)(vtkInterpolationInfo *info, const double point[3], double *outPtr)
void SetBorderModeToMirror()
The border mode (default: clamp).