VTK
|
convert image to b-spline knots More...
#include <vtkImageBSplineCoefficients.h>
Inherits vtkThreadedImageAlgorithm.
Public Types | |
typedef vtkThreadedImageAlgorithm | Superclass |
Public Member Functions | |
virtual int | IsA (const char *type) |
vtkImageBSplineCoefficients * | NewInstance () const |
void | PrintSelf (ostream &os, vtkIndent indent) |
int | CheckBounds (const double point[3]) |
int | SplitExtent (int splitExt[6], int startExt[6], int num, int total) |
virtual void | SetSplineDegree (int) |
virtual int | GetSplineDegree () |
virtual void | SetBorderMode (int) |
void | SetBorderModeToClamp () |
void | SetBorderModeToRepeat () |
void | SetBorderModeToMirror () |
virtual int | GetBorderMode () |
const char * | GetBorderModeAsString () |
virtual void | SetOutputScalarType (int) |
virtual int | GetOutputScalarType () |
void | SetOutputScalarTypeToFloat () |
void | SetOutputScalarTypeToDouble () |
const char * | GetOutputScalarTypeAsString () |
virtual void | SetBypass (int) |
virtual void | BypassOn () |
virtual void | BypassOff () |
virtual int | GetBypass () |
void | Evaluate (const double point[3], double *value) |
double | Evaluate (double x, double y, double z) |
double | Evaluate (const double point[3]) |
Static Public Member Functions | |
static vtkImageBSplineCoefficients * | New () |
static int | IsTypeOf (const char *type) |
static vtkImageBSplineCoefficients * | SafeDownCast (vtkObjectBase *o) |
Protected Member Functions | |
virtual vtkObjectBase * | NewInstanceInternal () const |
vtkImageBSplineCoefficients () | |
~vtkImageBSplineCoefficients () | |
virtual void | AllocateOutputData (vtkImageData *out, vtkInformation *outInfo, int *uExtent) |
virtual vtkImageData * | AllocateOutputData (vtkDataObject *out, vtkInformation *outInfo) |
virtual int | RequestData (vtkInformation *, vtkInformationVector **, vtkInformationVector *) |
virtual int | RequestInformation (vtkInformation *, vtkInformationVector **, vtkInformationVector *) |
virtual int | RequestUpdateExtent (vtkInformation *, vtkInformationVector **, vtkInformationVector *) |
virtual void | ThreadedExecute (vtkImageData *inData, vtkImageData *outData, int outExt[6], int threadId) |
Protected Attributes | |
int | SplineDegree |
int | BorderMode |
int | OutputScalarType |
int | Bypass |
int | DataWasPassed |
int | Iteration |
convert image to b-spline knots
vtkImageBSplineCoefficients prepares an image for b-spline interpolation by converting the image values into b-spline knot coefficients. It is a necessary pre-filtering step before applying b-spline interpolation with vtkImageReslice.
This class is based on code provided by Philippe Thevenaz of EPFL, Lausanne, Switzerland. Please acknowledge his contribution by citing the following paper: [1] P. Thevenaz, T. Blu, M. Unser, "Interpolation Revisited," IEEE Transactions on Medical Imaging 19(7):739-758, 2000.
The clamped boundary condition (which is the default) is taken from code presented in the following paper: [2] D. Ruijters, P. Thevenaz, "GPU Prefilter for Accurate Cubic B-spline Interpolation," The Computer Journal, doi: 10.1093/comjnl/bxq086, 2010.
Definition at line 55 of file vtkImageBSplineCoefficients.h.
typedef vtkThreadedImageAlgorithm vtkImageBSplineCoefficients::Superclass |
Definition at line 60 of file vtkImageBSplineCoefficients.h.
|
protected |
|
protected |
|
static |
|
static |
|
virtual |
|
static |
|
protectedvirtual |
vtkImageBSplineCoefficients* vtkImageBSplineCoefficients::NewInstance | ( | ) | const |
void vtkImageBSplineCoefficients::PrintSelf | ( | ostream & | os, |
vtkIndent | indent | ||
) |
|
virtual |
Set the degree of the spline polynomial. The default value is 3, and the maximum is 9.
|
virtual |
Set the degree of the spline polynomial. The default value is 3, and the maximum is 9.
|
virtual |
Set the border mode. The filter that is used to create the coefficients must repeat the image somehow to make a theoritically infinite input. The default is to clamp values that are off the edge of the image, to the value at the closest point on the edge. The other ways of virtually extending the image are to produce mirrored copies, which results in optimal smoothness at the boundary, or to repeat the image, which results in a cyclic or periodic spline.
|
inline |
Set the border mode. The filter that is used to create the coefficients must repeat the image somehow to make a theoritically infinite input. The default is to clamp values that are off the edge of the image, to the value at the closest point on the edge. The other ways of virtually extending the image are to produce mirrored copies, which results in optimal smoothness at the boundary, or to repeat the image, which results in a cyclic or periodic spline.
Definition at line 81 of file vtkImageBSplineCoefficients.h.
|
inline |
Set the border mode. The filter that is used to create the coefficients must repeat the image somehow to make a theoritically infinite input. The default is to clamp values that are off the edge of the image, to the value at the closest point on the edge. The other ways of virtually extending the image are to produce mirrored copies, which results in optimal smoothness at the boundary, or to repeat the image, which results in a cyclic or periodic spline.
Definition at line 83 of file vtkImageBSplineCoefficients.h.
|
inline |
Set the border mode. The filter that is used to create the coefficients must repeat the image somehow to make a theoritically infinite input. The default is to clamp values that are off the edge of the image, to the value at the closest point on the edge. The other ways of virtually extending the image are to produce mirrored copies, which results in optimal smoothness at the boundary, or to repeat the image, which results in a cyclic or periodic spline.
Definition at line 85 of file vtkImageBSplineCoefficients.h.
|
virtual |
Set the border mode. The filter that is used to create the coefficients must repeat the image somehow to make a theoritically infinite input. The default is to clamp values that are off the edge of the image, to the value at the closest point on the edge. The other ways of virtually extending the image are to produce mirrored copies, which results in optimal smoothness at the boundary, or to repeat the image, which results in a cyclic or periodic spline.
const char* vtkImageBSplineCoefficients::GetBorderModeAsString | ( | ) |
Set the border mode. The filter that is used to create the coefficients must repeat the image somehow to make a theoritically infinite input. The default is to clamp values that are off the edge of the image, to the value at the closest point on the edge. The other ways of virtually extending the image are to produce mirrored copies, which results in optimal smoothness at the boundary, or to repeat the image, which results in a cyclic or periodic spline.
|
virtual |
Set the scalar type of the output. Default is float. Floating-point output is used to avoid overflow, since the range of the output values is larger than the input values.
|
virtual |
Set the scalar type of the output. Default is float. Floating-point output is used to avoid overflow, since the range of the output values is larger than the input values.
|
inline |
Set the scalar type of the output. Default is float. Floating-point output is used to avoid overflow, since the range of the output values is larger than the input values.
Definition at line 97 of file vtkImageBSplineCoefficients.h.
|
inline |
Set the scalar type of the output. Default is float. Floating-point output is used to avoid overflow, since the range of the output values is larger than the input values.
Definition at line 99 of file vtkImageBSplineCoefficients.h.
const char* vtkImageBSplineCoefficients::GetOutputScalarTypeAsString | ( | ) |
Set the scalar type of the output. Default is float. Floating-point output is used to avoid overflow, since the range of the output values is larger than the input values.
|
virtual |
Bypass the filter, do not do any processing. If this is on, then the output data will reference the input data directly, and the output type will be the same as the input type. This is useful a downstream filter sometimes uses b-spline interpolation and sometimes uses other forms of interpolation.
|
virtual |
Bypass the filter, do not do any processing. If this is on, then the output data will reference the input data directly, and the output type will be the same as the input type. This is useful a downstream filter sometimes uses b-spline interpolation and sometimes uses other forms of interpolation.
|
virtual |
Bypass the filter, do not do any processing. If this is on, then the output data will reference the input data directly, and the output type will be the same as the input type. This is useful a downstream filter sometimes uses b-spline interpolation and sometimes uses other forms of interpolation.
|
virtual |
Bypass the filter, do not do any processing. If this is on, then the output data will reference the input data directly, and the output type will be the same as the input type. This is useful a downstream filter sometimes uses b-spline interpolation and sometimes uses other forms of interpolation.
int vtkImageBSplineCoefficients::CheckBounds | ( | const double | point[3] | ) |
Check a point against the image bounds. Return 0 if out of bounds, and 1 if inside bounds. Calling Evaluate on a point outside the bounds will not generate an error, but the value returned will depend on the BorderMode.
void vtkImageBSplineCoefficients::Evaluate | ( | const double | point[3], |
double * | value | ||
) |
Interpolate a value from the image. You must call Update() before calling this method for the first time. The first signature can return multiple components, while the second signature is for use on single-component images.
double vtkImageBSplineCoefficients::Evaluate | ( | double | x, |
double | y, | ||
double | z | ||
) |
Interpolate a value from the image. You must call Update() before calling this method for the first time. The first signature can return multiple components, while the second signature is for use on single-component images.
|
inline |
Interpolate a value from the image. You must call Update() before calling this method for the first time. The first signature can return multiple components, while the second signature is for use on single-component images.
Definition at line 128 of file vtkImageBSplineCoefficients.h.
int vtkImageBSplineCoefficients::SplitExtent | ( | int | splitExt[6], |
int | startExt[6], | ||
int | num, | ||
int | total | ||
) |
Internal method. Override SplitExtent so that the full extent is available in the direction currently being processed.
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protected |
Definition at line 155 of file vtkImageBSplineCoefficients.h.
|
protected |
Definition at line 156 of file vtkImageBSplineCoefficients.h.
|
protected |
Definition at line 157 of file vtkImageBSplineCoefficients.h.
|
protected |
Definition at line 158 of file vtkImageBSplineCoefficients.h.
|
protected |
Definition at line 159 of file vtkImageBSplineCoefficients.h.
|
protected |
Definition at line 160 of file vtkImageBSplineCoefficients.h.