VTK
vtkImageBSplineCoefficients.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageBSplineCoefficients.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
47 #ifndef vtkImageBSplineCoefficients_h
48 #define vtkImageBSplineCoefficients_h
49 
50 
51 #include "vtkImagingCoreModule.h" // For export macro
53 #include "vtkImageBSplineInterpolator.h" // for constants
54 
57 {
58 public:
61 
62  void PrintSelf(ostream& os, vtkIndent indent);
63 
65 
67  vtkSetClampMacro(SplineDegree, int, 0, VTK_IMAGE_BSPLINE_DEGREE_MAX);
68  vtkGetMacro(SplineDegree, int);
70 
72 
79  vtkSetClampMacro(BorderMode, int,
82  this->SetBorderMode(VTK_IMAGE_BORDER_CLAMP); }
84  this->SetBorderMode(VTK_IMAGE_BORDER_REPEAT); }
86  this->SetBorderMode(VTK_IMAGE_BORDER_MIRROR); }
87  vtkGetMacro(BorderMode, int);
88  const char *GetBorderModeAsString();
90 
92 
95  vtkSetClampMacro(OutputScalarType, int, VTK_FLOAT, VTK_DOUBLE);
96  vtkGetMacro(OutputScalarType, int);
98  this->SetOutputScalarType(VTK_FLOAT); }
100  this->SetOutputScalarType(VTK_DOUBLE); }
101  const char *GetOutputScalarTypeAsString();
103 
105 
110  vtkSetMacro(Bypass, int);
111  vtkBooleanMacro(Bypass, int);
112  vtkGetMacro(Bypass, int);
114 
119  int CheckBounds(const double point[3]);
120 
122 
126  void Evaluate(const double point[3], double *value);
127  double Evaluate(double x, double y, double z);
128  double Evaluate(const double point[3]) {
129  return this->Evaluate(point[0], point[1], point[2]); }
131 
134  int SplitExtent(int splitExt[6], int startExt[6], int num, int total);
135 
136 protected:
139 
140  virtual void AllocateOutputData(
141  vtkImageData *out, vtkInformation *outInfo, int *uExtent);
143  vtkDataObject *out, vtkInformation* outInfo);
144 
145  virtual int RequestData(
147  virtual int RequestInformation(
149  virtual int RequestUpdateExtent(
151 
152  virtual void ThreadedExecute(vtkImageData *inData, vtkImageData *outData,
153  int outExt[6], int threadId);
154 
158  int Bypass;
161 
162 private:
163  vtkImageBSplineCoefficients(const vtkImageBSplineCoefficients&); // Not implemented.
164  void operator=(const vtkImageBSplineCoefficients&); // Not implemented.
165 };
166 
167 #endif
virtual void ThreadedExecute(vtkImageData *inData, vtkImageData *outData, int extent[6], int threadId)
double Evaluate(const double point[3])
Store vtkAlgorithm input/output information.
convert image to b-spline knots
virtual int SplitExtent(int splitExt[6], int startExt[6], int num, int total)
#define VTK_IMAGE_BORDER_REPEAT
#define VTK_IMAGE_BORDER_CLAMP
#define VTK_IMAGE_BSPLINE_DEGREE_MAX
void PrintSelf(ostream &os, vtkIndent indent)
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
virtual void AllocateOutputData(vtkImageData *out, vtkInformation *outInfo, int *uExtent)
#define VTK_DOUBLE
Definition: vtkType.h:36
Generic filter that has one input..
#define VTK_FLOAT
Definition: vtkType.h:35
a simple class to control print indentation
Definition: vtkIndent.h:38
topologically and geometrically regular array of data
Definition: vtkImageData.h:44
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
#define VTKIMAGINGCORE_EXPORT
#define VTK_IMAGE_BORDER_MIRROR
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
Store zero or more vtkInformation instances.
static vtkAlgorithm * New()
general representation of visualization data
Definition: vtkDataObject.h:64