VTK
vtkVoxelModeller.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkVoxelModeller.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 =========================================================================*/
33 #ifndef vtkVoxelModeller_h
34 #define vtkVoxelModeller_h
35 
36 #include "vtkImagingHybridModule.h" // For export macro
37 #include "vtkImageAlgorithm.h"
38 
40 {
41 public:
43  void PrintSelf(ostream& os, vtkIndent indent);
44 
50  static vtkVoxelModeller *New();
51 
53  double ComputeModelBounds(double origin[3], double ar[3]);
54 
56 
58  void SetSampleDimensions(int i, int j, int k);
59  void SetSampleDimensions(int dim[3]);
60  vtkGetVectorMacro(SampleDimensions,int,3);
62 
64 
66  vtkSetClampMacro(MaximumDistance,double,0.0,1.0);
67  vtkGetMacro(MaximumDistance,double);
69 
71 
73  void SetModelBounds(const double bounds[6]);
74  void SetModelBounds(double xmin, double xmax, double ymin, double ymax, double zmin, double zmax);
75  vtkGetVectorMacro(ModelBounds,double,6);
77 
79 
82  vtkSetMacro(ScalarType,int);
83  void SetScalarTypeToFloat(){this->SetScalarType(VTK_FLOAT);};
84  void SetScalarTypeToDouble(){this->SetScalarType(VTK_DOUBLE);};
85  void SetScalarTypeToInt(){this->SetScalarType(VTK_INT);};
87  {this->SetScalarType(VTK_UNSIGNED_INT);};
88  void SetScalarTypeToLong(){this->SetScalarType(VTK_LONG);};
90  {this->SetScalarType(VTK_UNSIGNED_LONG);};
91  void SetScalarTypeToShort(){this->SetScalarType(VTK_SHORT);};
93  {this->SetScalarType(VTK_UNSIGNED_SHORT);};
95  {this->SetScalarType(VTK_UNSIGNED_CHAR);};
97  {this->SetScalarType(VTK_CHAR);};
99  {this->SetScalarType(VTK_BIT);};
100  vtkGetMacro(ScalarType,int);
102 
104 
108  vtkSetMacro(ForegroundValue, double);
109  vtkGetMacro(ForegroundValue, double);
110  vtkSetMacro(BackgroundValue, double);
111  vtkGetMacro(BackgroundValue, double);
112 protected:
116 
120 
121  // see vtkAlgorithm for details
122  virtual int RequestData(vtkInformation *request,
123  vtkInformationVector** inputVector,
124  vtkInformationVector* outputVector);
125 
126  // see algorithm for more info
128 
129  int SampleDimensions[3];
131  double ModelBounds[6];
135 
136 private:
137  vtkVoxelModeller(const vtkVoxelModeller&); // Not implemented.
138  void operator=(const vtkVoxelModeller&); // Not implemented.
139 };
140 
141 #endif
vtkVoxelModeller::SetModelBounds
void SetModelBounds(const double bounds[6])
vtkVoxelModeller::SetScalarTypeToUnsignedInt
void SetScalarTypeToUnsignedInt()
Definition: vtkVoxelModeller.h:86
vtkVoxelModeller::ScalarType
int ScalarType
Definition: vtkVoxelModeller.h:134
VTK_UNSIGNED_INT
#define VTK_UNSIGNED_INT
Definition: vtkType.h:32
vtkVoxelModeller::SetScalarTypeToUnsignedShort
void SetScalarTypeToUnsignedShort()
Definition: vtkVoxelModeller.h:92
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:41
vtkVoxelModeller::SetScalarTypeToShort
void SetScalarTypeToShort()
Definition: vtkVoxelModeller.h:91
VTK_UNSIGNED_SHORT
#define VTK_UNSIGNED_SHORT
Definition: vtkType.h:30
vtkVoxelModeller::vtkVoxelModeller
vtkVoxelModeller()
vtkVoxelModeller::SetScalarTypeToBit
void SetScalarTypeToBit()
Definition: vtkVoxelModeller.h:98
vtkTypeMacro
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:642
vtkImageAlgorithm.h
vtkVoxelModeller::ComputeModelBounds
double ComputeModelBounds(double origin[3], double ar[3])
vtkImageAlgorithm
Generic algorithm superclass for image algs.
Definition: vtkImageAlgorithm.h:40
vtkImagingHybridModule.h
vtkGetVectorMacro
#define vtkGetVectorMacro(name, type, count)
Definition: vtkSetGet.h:424
VTKIMAGINGHYBRID_EXPORT
#define VTKIMAGINGHYBRID_EXPORT
Definition: vtkImagingHybridModule.h:15
vtkVoxelModeller::BackgroundValue
double BackgroundValue
Definition: vtkVoxelModeller.h:133
vtkVoxelModeller::FillInputPortInformation
virtual int FillInputPortInformation(int port, vtkInformation *info)
vtkX3D::port
@ port
Definition: vtkX3D.h:447
vtkSetClampMacro
#define vtkSetClampMacro(name, type, min, max)
Definition: vtkSetGet.h:143
vtkVoxelModeller::SetModelBounds
void SetModelBounds(double xmin, double xmax, double ymin, double ymax, double zmin, double zmax)
vtkVoxelModeller::SetScalarTypeToUnsignedLong
void SetScalarTypeToUnsignedLong()
Definition: vtkVoxelModeller.h:89
vtkVoxelModeller::SetScalarTypeToUnsignedChar
void SetScalarTypeToUnsignedChar()
Definition: vtkVoxelModeller.h:94
VTK_CHAR
#define VTK_CHAR
Definition: vtkType.h:26
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
VTK_FLOAT
#define VTK_FLOAT
Definition: vtkType.h:35
vtkVoxelModeller::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent)
VTK_DOUBLE
#define VTK_DOUBLE
Definition: vtkType.h:36
VTK_UNSIGNED_CHAR
#define VTK_UNSIGNED_CHAR
Definition: vtkType.h:28
VTK_LONG
#define VTK_LONG
Definition: vtkType.h:33
vtkGetMacro
#define vtkGetMacro(name, type)
Definition: vtkSetGet.h:93
vtkgl::zmax
GLclampd zmax
Definition: vtkgl.h:17479
vtkVoxelModeller::RequestInformation
virtual int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
vtkVoxelModeller::ForegroundValue
double ForegroundValue
Definition: vtkVoxelModeller.h:132
vtkVoxelModeller::SetScalarTypeToChar
void SetScalarTypeToChar()
Definition: vtkVoxelModeller.h:96
vtkVoxelModeller::SetScalarTypeToDouble
void SetScalarTypeToDouble()
Definition: vtkVoxelModeller.h:84
VTK_UNSIGNED_LONG
#define VTK_UNSIGNED_LONG
Definition: vtkType.h:34
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:86
vtkSetMacro
vtkSetMacro(IgnoreDriverBugs, bool)
vtkX3D::info
@ info
Definition: vtkX3D.h:376
vtkVoxelModeller::RequestData
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
VTK_SHORT
#define VTK_SHORT
Definition: vtkType.h:29
vtkVoxelModeller::New
static vtkVoxelModeller * New()
VTK_BIT
#define VTK_BIT
Definition: vtkType.h:25
vtkVoxelModeller::SetScalarTypeToFloat
void SetScalarTypeToFloat()
Definition: vtkVoxelModeller.h:83
VTK_INT
#define VTK_INT
Definition: vtkType.h:31
vtkVoxelModeller::SetScalarTypeToLong
void SetScalarTypeToLong()
Definition: vtkVoxelModeller.h:88
vtkVoxelModeller::SetSampleDimensions
void SetSampleDimensions(int dim[3])
vtkVoxelModeller::SetScalarTypeToInt
void SetScalarTypeToInt()
Definition: vtkVoxelModeller.h:85
vtkVoxelModeller::~vtkVoxelModeller
~vtkVoxelModeller()
Definition: vtkVoxelModeller.h:114
vtkVoxelModeller
convert an arbitrary dataset to a voxel representation
Definition: vtkVoxelModeller.h:40
vtkVoxelModeller::MaximumDistance
double MaximumDistance
Definition: vtkVoxelModeller.h:130
vtkVoxelModeller::SetSampleDimensions
void SetSampleDimensions(int i, int j, int k)