VTK
vtkCheckerboardSplatter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkCheckerboardSplatter.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 =========================================================================*/
97 #ifndef vtkCheckerboardSplatter_h
98 #define vtkCheckerboardSplatter_h
99 
100 #include "vtkImagingHybridModule.h" // For export macro
101 #include "vtkImageAlgorithm.h"
102 
103 #define VTK_ACCUMULATION_MODE_MIN 0
104 #define VTK_ACCUMULATION_MODE_MAX 1
105 #define VTK_ACCUMULATION_MODE_SUM 2
106 
107 class vtkDoubleArray;
108 class vtkCompositeDataSet;
109 
111 {
112 public:
114  void PrintSelf(ostream& os, vtkIndent indent);
115 
119  static vtkCheckerboardSplatter *New();
120 
122 
124  void SetSampleDimensions(int i, int j, int k);
125  void SetSampleDimensions(int dim[3]);
126  vtkGetVectorMacro(SampleDimensions,int,3);
128 
130 
134  vtkSetVector6Macro(ModelBounds,double);
135  vtkGetVectorMacro(ModelBounds,double,6);
137 
139 
147  vtkSetClampMacro(Footprint,int,0,VTK_INT_MAX);
148  vtkGetMacro(Footprint,int);
150 
152 
156  vtkSetClampMacro(Radius,double,0.0,VTK_DOUBLE_MAX);
157  vtkGetMacro(Radius,double);
159 
161 
164  vtkSetClampMacro(ScaleFactor,double,0.0,VTK_DOUBLE_MAX);
165  vtkGetMacro(ScaleFactor,double);
167 
169 
172  vtkSetMacro(ExponentFactor,double);
173  vtkGetMacro(ExponentFactor,double);
175 
177 
178  vtkSetMacro(ScalarWarping,int);
179  vtkGetMacro(ScalarWarping,int);
180  vtkBooleanMacro(ScalarWarping,int);
182 
184 
187  vtkSetMacro(NormalWarping,int);
188  vtkGetMacro(NormalWarping,int);
189  vtkBooleanMacro(NormalWarping,int);
191 
193 
198  vtkSetClampMacro(Eccentricity,double,0.001,VTK_DOUBLE_MAX);
199  vtkGetMacro(Eccentricity,double);
201 
203 
210  vtkSetClampMacro(AccumulationMode,int,
212  vtkGetMacro(AccumulationMode,int);
214  {this->SetAccumulationMode(VTK_ACCUMULATION_MODE_MIN);}
216  {this->SetAccumulationMode(VTK_ACCUMULATION_MODE_MAX);}
218  {this->SetAccumulationMode(VTK_ACCUMULATION_MODE_SUM);}
219  const char *GetAccumulationModeAsString();
221 
223 
226  vtkSetMacro(OutputScalarType,int);
227  vtkGetMacro(OutputScalarType,int);
229  {this->SetOutputScalarType(VTK_DOUBLE);}
231  {this->SetOutputScalarType(VTK_FLOAT);}
233 
235 
238  vtkSetMacro(Capping,int);
239  vtkGetMacro(Capping,int);
240  vtkBooleanMacro(Capping,int);
242 
244 
246  vtkSetMacro(CapValue,double);
247  vtkGetMacro(CapValue,double);
249 
251 
256  vtkSetMacro(NullValue,double);
257  vtkGetMacro(NullValue,double);
259 
261 
267  vtkSetClampMacro(MaximumDimension,int,0,255);
268  vtkGetMacro(MaximumDimension,int);
270 
272 
277  vtkSetClampMacro(ParallelSplatCrossover,int,0,255);
278  vtkGetMacro(ParallelSplatCrossover,int);
280 
282 
284  void ComputeModelBounds(vtkDataSet *input, vtkImageData *output,
285  vtkInformation *outInfo);
287 
288 protected:
291 
293  virtual int RequestInformation (vtkInformation *,
296  virtual int RequestData(vtkInformation *,
299 
300  int OutputScalarType; //the type of output scalars
301  int SampleDimensions[3]; // dimensions of volume to splat into
302  double Radius; // Radius factor in the Gaussian exponential function
303  int Footprint; // maximum distance splat propagates (in voxels 0->Dim)
304  double ExponentFactor; // scale exponent of gaussian function
305  double ModelBounds[6]; // bounding box of splatting dimensions
306  double Origin[3], Spacing[3]; // output geometry
307  int NormalWarping; // on/off warping of splat via normal
308  double Eccentricity;// elliptic distortion due to normals
309  int ScalarWarping; // on/off warping of splat via scalar
310  double ScaleFactor; // splat size influenced by scale factor
311  int Capping; // Cap side of volume to close surfaces
312  double CapValue; // value to use for capping
313  int AccumulationMode; // how to combine scalar values
314  double NullValue; // initial value of voxels
315  unsigned char MaximumDimension; // max resolution of checkerboard
316  int ParallelSplatCrossover; //the point at which parallel splatting occurs
317 
318 private:
319  vtkCheckerboardSplatter(const vtkCheckerboardSplatter&); // Not implemented.
320  void operator=(const vtkCheckerboardSplatter&); // Not implemented.
321 };
322 
323 #endif
#define VTK_DOUBLE_MAX
Definition: vtkType.h:140
Store vtkAlgorithm input/output information.
#define VTK_ACCUMULATION_MODE_MIN
#define VTK_ACCUMULATION_MODE_MAX
abstract class to specify dataset behavior
Definition: vtkDataSet.h:61
#define VTK_INT_MAX
Definition: vtkType.h:130
dynamic, self-adjusting array of double
#define VTK_DOUBLE
Definition: vtkType.h:36
splat points into a volume with an elliptical, Gaussian distribution
#define VTK_FLOAT
Definition: vtkType.h:35
abstract superclass for composite (multi-block or AMR) datasets
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 VTK_ACCUMULATION_MODE_SUM
virtual int FillInputPortInformation(int port, vtkInformation *info)
Generic algorithm superclass for image algs.
Store zero or more vtkInformation instances.
void PrintSelf(ostream &os, vtkIndent indent)
static vtkAlgorithm * New()
#define VTKIMAGINGHYBRID_EXPORT
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)