www.mooseframework.org
Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
ImageSampler Class Reference

A helper class for reading and sampling images using VTK. More...

#include <ImageSampler.h>

Inheritance diagram for ImageSampler:
[legend]

Public Member Functions

 ImageSampler (const InputParameters &parameters)
 Constructor. More...
 
virtual Real sample (const Point &p)
 Return the pixel value for the given point. More...
 
virtual void setupImageSampler (MooseMesh &mesh)
 Perform initialization of image data. More...
 
std::string fileSuffix ()
 
const std::vector< std::string > & filenames ()
 

Protected Member Functions

void vtkShiftAndScale ()
 Apply image re-scaling using the vtkImageShiftAndRescale object. More...
 
void vtkThreshold ()
 Perform thresholding. More...
 
void vtkMagnitude ()
 Convert the image to greyscale. More...
 
void vtkFlip ()
 Perform image flipping. More...
 
void errorCheck ()
 

Protected Attributes

int _status
 
std::string _file_suffix
 
std::vector< std::string > _filenames
 

Private Member Functions

vtkSmartPointer< vtkImageFlip > imageFlip (const int &axis)
 Helper method for flipping image. More...
 

Private Attributes

vtkSmartPointer< vtkStringArray > _files
 List of file names to extract data. More...
 
vtkImageData * _data
 Complete image data. More...
 
vtkAlgorithmOutput * _algorithm
 VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers... More...
 
vtkSmartPointer< vtkImageReader2 > _image
 Complete image data. More...
 
vtkSmartPointer< vtkImageThreshold > _image_threshold
 Pointer to thresholding filter. More...
 
vtkSmartPointer< vtkImageShiftScale > _shift_scale_filter
 Pointer to the shift and scaling filter. More...
 
vtkSmartPointer< vtkImageMagnitude > _magnitude_filter
 Pointer to the magnitude filter. More...
 
vtkSmartPointer< vtkImageFlip > _flip_filter
 Pointers to image flipping filter. May be used for x, y, or z. More...
 
Point _origin
 Origin of image. More...
 
std::vector< int > _dims
 Pixel dimension of image. More...
 
Point _physical_dims
 Physical dimensions of image. More...
 
std::vector< double > _voxel
 Physical pixel size. More...
 
unsigned int _component
 Component to extract. More...
 
BoundingBox _bounding_box
 Bounding box for testing points. More...
 
const InputParameters_is_pars
 Parameters for interface. More...
 
ConsoleStream _is_console
 Create a console stream object for this helper class. More...
 

Detailed Description

A helper class for reading and sampling images using VTK.

Definition at line 57 of file ImageSampler.h.

Constructor & Destructor Documentation

ImageSampler::ImageSampler ( const InputParameters parameters)

Constructor.

Use this object as an interface, being sure to also add the parameters to the child class.

See also
ImageFunction

Definition at line 62 of file ImageSampler.C.

63  : FileRangeBuilder(parameters),
64 #ifdef LIBMESH_HAVE_VTK
65  _data(NULL),
66  _algorithm(NULL),
67 #endif
68  _is_pars(parameters),
69  _is_console((parameters.getCheckedPointerParam<MooseApp *>("_moose_app"))->getOutputWarehouse())
70 
71 {
72 #ifndef LIBMESH_HAVE_VTK
73  // This should be impossible to reach, the registration of ImageSampler is also guarded with
74  // LIBMESH_HAVE_VTK
75  mooseError("libMesh must be configured with VTK enabled to utilize ImageSampler");
76 #endif
77 }
vtkAlgorithmOutput * _algorithm
VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers...
Definition: ImageSampler.h:116
void mooseError(Args &&...args)
Emit an error message with the given stringified, concatenated args and terminate the application...
Definition: MooseError.h:182
Base class for MOOSE-based applications.
Definition: MooseApp.h:58
ConsoleStream _is_console
Create a console stream object for this helper class.
Definition: ImageSampler.h:167
vtkImageData * _data
Complete image data.
Definition: ImageSampler.h:113
T getCheckedPointerParam(const std::string &name, const std::string &error_string="") const
Verifies that the requested parameter exists and is not NULL and returns it to the caller...
const InputParameters & _is_pars
Parameters for interface.
Definition: ImageSampler.h:164
FileRangeBuilder(const InputParameters &params)

Member Function Documentation

void FileRangeBuilder::errorCheck ( )
protectedinherited

Definition at line 156 of file FileRangeBuilder.C.

Referenced by FileRangeBuilder::filenames(), and ImageMesh::ImageMesh().

157 {
158  switch (_status)
159  {
160  case 0:
161  return;
162  case 1:
163  mooseError("Cannot provide both file and file_base parameters");
164  break;
165  case 2:
166  mooseError("You must provide a valid value for either the 'file' parameter or the "
167  "'file_base' parameter.");
168  break;
169  case 3:
170  mooseError(
171  "If you provide a 'file_base', you must also provide a valid 'file_suffix', e.g. 'png'.");
172  break;
173  default:
174  mooseError("Unknown error code!");
175  }
176 }
void mooseError(Args &&...args)
Emit an error message with the given stringified, concatenated args and terminate the application...
Definition: MooseError.h:182
const std::vector<std::string>& FileRangeBuilder::filenames ( )
inlineinherited

Definition at line 44 of file FileRangeBuilder.h.

Referenced by setupImageSampler().

44 { return _filenames; }
std::vector< std::string > _filenames
std::string FileRangeBuilder::fileSuffix ( )
inlineinherited

Definition at line 43 of file FileRangeBuilder.h.

Referenced by setupImageSampler().

43 { return _file_suffix; }
std::string _file_suffix
vtkSmartPointer< vtkImageFlip > ImageSampler::imageFlip ( const int &  axis)
private

Helper method for flipping image.

Parameters
axisFlag for determing the flip axis: "x=0", "y=1", "z=2"
Returns
A smart pointer the flipping filter

Definition at line 360 of file ImageSampler.C.

Referenced by vtkFlip().

361 {
362  vtkSmartPointer<vtkImageFlip> flip_image = vtkSmartPointer<vtkImageFlip>::New();
363 
364  flip_image->SetFilteredAxis(axis);
365 
366  // Set the data source
367  flip_image->SetInputConnection(_algorithm);
368 
369  // Perform the flip
370  flip_image->Update();
371 
372  // Return the flip filter pointer
373  return flip_image;
374 }
vtkAlgorithmOutput * _algorithm
VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers...
Definition: ImageSampler.h:116
Real ImageSampler::sample ( const Point &  p)
virtual

Return the pixel value for the given point.

Parameters
pThe point at which to extract pixel data

Definition at line 219 of file ImageSampler.C.

Referenced by ImageSubdomain::modify(), and ImageFunction::value().

220 {
221 #ifdef LIBMESH_HAVE_VTK
222 
223  // Do nothing if the point is outside of the image domain
224  if (!_bounding_box.contains_point(p))
225  return 0.0;
226 
227  // Determine pixel coordinates
228  std::vector<int> x(3, 0);
229  for (int i = 0; i < LIBMESH_DIM; ++i)
230  {
231  // Compute position, only if voxel size is greater than zero
232  if (_voxel[i] == 0)
233  x[i] = 0;
234 
235  else
236  {
237  x[i] = std::floor((p(i) - _origin(i)) / _voxel[i]);
238 
239  // If the point falls on the mesh extents the index needs to be decreased by one
240  if (x[i] == _dims[i])
241  x[i]--;
242  }
243  }
244 
245  // Return the image data at the given point
246  return _data->GetScalarComponentAsDouble(x[0], x[1], x[2], _component);
247 
248 #else
249  libmesh_ignore(p); // avoid un-used parameter warnings
250  return 0.0;
251 #endif
252 }
unsigned int _component
Component to extract.
Definition: ImageSampler.h:157
static PetscErrorCode Vec x
BoundingBox _bounding_box
Bounding box for testing points.
Definition: ImageSampler.h:161
vtkImageData * _data
Complete image data.
Definition: ImageSampler.h:113
std::vector< double > _voxel
Physical pixel size.
Definition: ImageSampler.h:153
Point _origin
Origin of image.
Definition: ImageSampler.h:144
std::vector< int > _dims
Pixel dimension of image.
Definition: ImageSampler.h:147
void ImageSampler::setupImageSampler ( MooseMesh mesh)
virtual

Perform initialization of image data.

Definition at line 80 of file ImageSampler.C.

Referenced by ImageFunction::initialSetup(), and ImageSubdomain::modify().

81 {
82  // Don't warn that mesh or _is_pars are unused when VTK is not enabled.
83  libmesh_ignore(mesh);
84  libmesh_ignore(_is_pars);
85 
86 #ifdef LIBMESH_HAVE_VTK
87  // Get access to the Mesh object
88  BoundingBox bbox = MeshTools::create_bounding_box(mesh.getMesh());
89 
90  // Set the dimensions from the Mesh if not set by the User
91  if (_is_pars.isParamValid("dimensions"))
92  _physical_dims = _is_pars.get<Point>("dimensions");
93 
94  else
95  {
96  _physical_dims(0) = bbox.max()(0) - bbox.min()(0);
97 #if LIBMESH_DIM > 1
98  _physical_dims(1) = bbox.max()(1) - bbox.min()(1);
99 #endif
100 #if LIBMESH_DIM > 2
101  _physical_dims(2) = bbox.max()(2) - bbox.min()(2);
102 #endif
103  }
104 
105  // Set the origin from the Mesh if not set in the input file
106  if (_is_pars.isParamValid("origin"))
107  _origin = _is_pars.get<Point>("origin");
108  else
109  {
110  _origin(0) = bbox.min()(0);
111 #if LIBMESH_DIM > 1
112  _origin(1) = bbox.min()(1);
113 #endif
114 #if LIBMESH_DIM > 2
115  _origin(2) = bbox.min()(2);
116 #endif
117  }
118 
119  // An array of filenames, to be filled in
120  std::vector<std::string> filenames;
121 
122  // The file suffix, to be determined
123  std::string file_suffix;
124 
125  // Try to parse our own file range parameters. If that fails, then
126  // see if the associated Mesh is an ImageMesh and use its. If that
127  // also fails, then we have to throw an error...
128  //
129  // The parseFileRange method sets parameters, thus a writable reference to the InputParameters
130  // object must be obtained from the warehouse. Generally, this should be avoided, but
131  // this is a special case.
132  if (_status != 0)
133  {
134  // We don't have parameters, so see if we can get them from ImageMesh
135  ImageMesh * image_mesh = dynamic_cast<ImageMesh *>(&mesh);
136  if (!image_mesh)
137  mooseError("No file range parameters were provided and the Mesh is not an ImageMesh.");
138 
139  // Get the ImageMesh's parameters. This should work, otherwise
140  // errors would already have been thrown...
141  filenames = image_mesh->filenames();
142  file_suffix = image_mesh->fileSuffix();
143  }
144  else
145  {
146  // Use our own parameters (using 'this' b/c of conflicts with filenames the local variable)
147  filenames = this->filenames();
148  file_suffix = fileSuffix();
149  }
150 
151  // Storage for the file names
152  _files = vtkSmartPointer<vtkStringArray>::New();
153 
154  for (const auto & filename : filenames)
155  _files->InsertNextValue(filename);
156 
157  // Error if no files where located
158  if (_files->GetNumberOfValues() == 0)
159  mooseError("No image file(s) located");
160 
161  // Read the image stack. Hurray for VTK not using polymorphism in a
162  // smart way... we actually have to explicitly create the type of
163  // reader based on the file extension, using an if-statement...
164  if (file_suffix == "png")
165  _image = vtkSmartPointer<vtkPNGReader>::New();
166  else if (file_suffix == "tiff" || file_suffix == "tif")
167  _image = vtkSmartPointer<vtkTIFFReader>::New();
168  else
169  mooseError("Un-supported file type '", file_suffix, "'");
170 
171  // Now that _image is set up, actually read the images
172  // Indicate that data read has started
173  _is_console << "Reading image(s)..." << std::endl;
174 
175  // Extract the data
176  _image->SetFileNames(_files);
177  _image->Update();
178  _data = _image->GetOutput();
179  _algorithm = _image->GetOutputPort();
180 
181  // Set the image dimensions and voxel size member variable
182  int * dims = _data->GetDimensions();
183  for (unsigned int i = 0; i < 3; ++i)
184  {
185  _dims.push_back(dims[i]);
186  _voxel.push_back(_physical_dims(i) / _dims[i]);
187  }
188 
189  // Set the dimensions of the image and bounding box
190  _data->SetSpacing(_voxel[0], _voxel[1], _voxel[2]);
191  _data->SetOrigin(_origin(0), _origin(1), _origin(2));
192  _bounding_box.min() = _origin;
194 
195  // Indicate data read is completed
196  _is_console << " ...image read finished" << std::endl;
197 
198  // Set the component parameter
199  // If the parameter is not set then vtkMagnitude() will applied
200  if (_is_pars.isParamValid("component"))
201  {
202  unsigned int n = _data->GetNumberOfScalarComponents();
203  _component = _is_pars.get<unsigned int>("component");
204  if (_component >= n)
205  mooseError("'component' parameter must be empty or have a value of 0 to ", n - 1);
206  }
207  else
208  _component = 0;
209 
210  // Apply filters, the toggling on and off of each filter is handled internally
211  vtkMagnitude();
213  vtkThreshold();
214  vtkFlip();
215 #endif
216 }
unsigned int _component
Component to extract.
Definition: ImageSampler.h:157
vtkAlgorithmOutput * _algorithm
VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers...
Definition: ImageSampler.h:116
void mooseError(Args &&...args)
Emit an error message with the given stringified, concatenated args and terminate the application...
Definition: MooseError.h:182
const std::vector< std::string > & filenames()
vtkSmartPointer< vtkImageReader2 > _image
Complete image data.
Definition: ImageSampler.h:119
ConsoleStream _is_console
Create a console stream object for this helper class.
Definition: ImageSampler.h:167
BoundingBox _bounding_box
Bounding box for testing points.
Definition: ImageSampler.h:161
vtkImageData * _data
Complete image data.
Definition: ImageSampler.h:113
std::vector< double > _voxel
Physical pixel size.
Definition: ImageSampler.h:153
std::string fileSuffix()
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.
MeshBase & getMesh()
Accessor for the underlying libMesh Mesh object.
Definition: MooseMesh.C:2408
void vtkShiftAndScale()
Apply image re-scaling using the vtkImageShiftAndRescale object.
Definition: ImageSampler.C:274
Point _origin
Origin of image.
Definition: ImageSampler.h:144
const InputParameters & _is_pars
Parameters for interface.
Definition: ImageSampler.h:164
void vtkThreshold()
Perform thresholding.
Definition: ImageSampler.C:301
vtkSmartPointer< vtkStringArray > _files
List of file names to extract data.
Definition: ImageSampler.h:110
Point _physical_dims
Physical dimensions of image.
Definition: ImageSampler.h:150
std::vector< int > _dims
Pixel dimension of image.
Definition: ImageSampler.h:147
void vtkFlip()
Perform image flipping.
Definition: ImageSampler.C:337
PetscInt n
void vtkMagnitude()
Convert the image to greyscale.
Definition: ImageSampler.C:255
A 2D GeneratedMesh where xmin, xmax, etc.
Definition: ImageMesh.h:29
void ImageSampler::vtkFlip ( )
protected

Perform image flipping.

Flip the image along the x, y, and/or z axis. If multiple flips occur, they happen in order.

Definition at line 337 of file ImageSampler.C.

Referenced by setupImageSampler().

338 {
339 #ifdef LIBMESH_HAVE_VTK
340  // Convert boolean values into an integer array, then loop over it
341  int mask[3] = {
342  _is_pars.get<bool>("flip_x"), _is_pars.get<bool>("flip_y"), _is_pars.get<bool>("flip_z")};
343 
344  for (int dim = 0; dim < 3; ++dim)
345  {
346  if (mask[dim])
347  {
348  _flip_filter = imageFlip(dim);
349 
350  // Update pointers
351  _data = _flip_filter->GetOutput();
352  _algorithm = _flip_filter->GetOutputPort();
353  }
354  }
355 #endif
356 }
vtkAlgorithmOutput * _algorithm
VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers...
Definition: ImageSampler.h:116
vtkSmartPointer< vtkImageFlip > _flip_filter
Pointers to image flipping filter. May be used for x, y, or z.
Definition: ImageSampler.h:131
vtkImageData * _data
Complete image data.
Definition: ImageSampler.h:113
const InputParameters & _is_pars
Parameters for interface.
Definition: ImageSampler.h:164
vtkSmartPointer< vtkImageFlip > imageFlip(const int &axis)
Helper method for flipping image.
Definition: ImageSampler.C:360
void ImageSampler::vtkMagnitude ( )
protected

Convert the image to greyscale.

By leaving the 'component' input parameter empty, this is called automatically.

Definition at line 255 of file ImageSampler.C.

Referenced by setupImageSampler().

256 {
257 #ifdef LIBMESH_HAVE_VTK
258  // Do nothing if 'component' is set
259  if (_is_pars.isParamValid("component"))
260  return;
261 
262  // Apply the greyscale filtering
263  _magnitude_filter = vtkSmartPointer<vtkImageMagnitude>::New();
264  _magnitude_filter->SetInputConnection(_algorithm);
265  _magnitude_filter->Update();
266 
267  // Update the pointers
268  _data = _magnitude_filter->GetOutput();
269  _algorithm = _magnitude_filter->GetOutputPort();
270 #endif
271 }
vtkAlgorithmOutput * _algorithm
VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers...
Definition: ImageSampler.h:116
vtkImageData * _data
Complete image data.
Definition: ImageSampler.h:113
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.
vtkSmartPointer< vtkImageMagnitude > _magnitude_filter
Pointer to the magnitude filter.
Definition: ImageSampler.h:128
const InputParameters & _is_pars
Parameters for interface.
Definition: ImageSampler.h:164
void ImageSampler::vtkShiftAndScale ( )
protected

Apply image re-scaling using the vtkImageShiftAndRescale object.

Definition at line 274 of file ImageSampler.C.

Referenced by setupImageSampler().

275 {
276 #ifdef LIBMESH_HAVE_VTK
277  // Capture the parameters
278  double shift = _is_pars.get<double>("shift");
279  double scale = _is_pars.get<double>("scale");
280 
281  // Do nothing if shift and scale are not set
282  if (shift == 0 && scale == 1)
283  return;
284 
285  // Perform the scaling and offset actions
286  _shift_scale_filter = vtkSmartPointer<vtkImageShiftScale>::New();
287  _shift_scale_filter->SetOutputScalarTypeToDouble();
288 
289  _shift_scale_filter->SetInputConnection(_algorithm);
290  _shift_scale_filter->SetShift(shift);
291  _shift_scale_filter->SetScale(scale);
292  _shift_scale_filter->Update();
293 
294  // Update the pointers
295  _data = _shift_scale_filter->GetOutput();
296  _algorithm = _shift_scale_filter->GetOutputPort();
297 #endif
298 }
vtkAlgorithmOutput * _algorithm
VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers...
Definition: ImageSampler.h:116
vtkImageData * _data
Complete image data.
Definition: ImageSampler.h:113
vtkSmartPointer< vtkImageShiftScale > _shift_scale_filter
Pointer to the shift and scaling filter.
Definition: ImageSampler.h:125
const InputParameters & _is_pars
Parameters for interface.
Definition: ImageSampler.h:164
void ImageSampler::vtkThreshold ( )
protected

Perform thresholding.

Definition at line 301 of file ImageSampler.C.

Referenced by setupImageSampler().

302 {
303 #ifdef LIBMESH_HAVE_VTK
304  // Do nothing if threshold not set
305  if (!_is_pars.isParamValid("threshold"))
306  return;
307 
308  // Error if both upper and lower are not set
309  if (!_is_pars.isParamValid("upper_value") || !_is_pars.isParamValid("lower_value"))
310  mooseError("When thresholding is applied, both the upper_value and lower_value parameters must "
311  "be set");
312 
313  // Create the thresholding object
314  _image_threshold = vtkSmartPointer<vtkImageThreshold>::New();
315 
316  // Set the data source
317  _image_threshold->SetInputConnection(_algorithm);
318 
319  // Setup the thresholding options
320  _image_threshold->ThresholdByUpper(_is_pars.get<Real>("threshold"));
321  _image_threshold->ReplaceInOn();
322  _image_threshold->SetInValue(_is_pars.get<Real>("upper_value"));
323  _image_threshold->ReplaceOutOn();
324  _image_threshold->SetOutValue(_is_pars.get<Real>("lower_value"));
325  _image_threshold->SetOutputScalarTypeToDouble();
326 
327  // Perform the thresholding
328  _image_threshold->Update();
329 
330  // Update the pointers
331  _data = _image_threshold->GetOutput();
332  _algorithm = _image_threshold->GetOutputPort();
333 #endif
334 }
vtkAlgorithmOutput * _algorithm
VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers...
Definition: ImageSampler.h:116
void mooseError(Args &&...args)
Emit an error message with the given stringified, concatenated args and terminate the application...
Definition: MooseError.h:182
vtkImageData * _data
Complete image data.
Definition: ImageSampler.h:113
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.
const InputParameters & _is_pars
Parameters for interface.
Definition: ImageSampler.h:164
vtkSmartPointer< vtkImageThreshold > _image_threshold
Pointer to thresholding filter.
Definition: ImageSampler.h:122

Member Data Documentation

vtkAlgorithmOutput* ImageSampler::_algorithm
private

VTK-6 seems to work better in terms of "algorithm outputs" rather than vtkImageData pointers...

Definition at line 116 of file ImageSampler.h.

Referenced by imageFlip(), setupImageSampler(), vtkFlip(), vtkMagnitude(), vtkShiftAndScale(), and vtkThreshold().

BoundingBox ImageSampler::_bounding_box
private

Bounding box for testing points.

Definition at line 161 of file ImageSampler.h.

Referenced by sample(), and setupImageSampler().

unsigned int ImageSampler::_component
private

Component to extract.

Definition at line 157 of file ImageSampler.h.

Referenced by sample(), and setupImageSampler().

vtkImageData* ImageSampler::_data
private

Complete image data.

Definition at line 113 of file ImageSampler.h.

Referenced by sample(), setupImageSampler(), vtkFlip(), vtkMagnitude(), vtkShiftAndScale(), and vtkThreshold().

std::vector<int> ImageSampler::_dims
private

Pixel dimension of image.

Definition at line 147 of file ImageSampler.h.

Referenced by sample(), and setupImageSampler().

std::string FileRangeBuilder::_file_suffix
protectedinherited
std::vector<std::string> FileRangeBuilder::_filenames
protectedinherited
vtkSmartPointer<vtkStringArray> ImageSampler::_files
private

List of file names to extract data.

Definition at line 110 of file ImageSampler.h.

Referenced by setupImageSampler().

vtkSmartPointer<vtkImageFlip> ImageSampler::_flip_filter
private

Pointers to image flipping filter. May be used for x, y, or z.

Definition at line 131 of file ImageSampler.h.

Referenced by vtkFlip().

vtkSmartPointer<vtkImageReader2> ImageSampler::_image
private

Complete image data.

Definition at line 119 of file ImageSampler.h.

Referenced by setupImageSampler().

vtkSmartPointer<vtkImageThreshold> ImageSampler::_image_threshold
private

Pointer to thresholding filter.

Definition at line 122 of file ImageSampler.h.

Referenced by vtkThreshold().

ConsoleStream ImageSampler::_is_console
private

Create a console stream object for this helper class.

Definition at line 167 of file ImageSampler.h.

Referenced by setupImageSampler().

const InputParameters& ImageSampler::_is_pars
private

Parameters for interface.

Definition at line 164 of file ImageSampler.h.

Referenced by setupImageSampler(), vtkFlip(), vtkMagnitude(), vtkShiftAndScale(), and vtkThreshold().

vtkSmartPointer<vtkImageMagnitude> ImageSampler::_magnitude_filter
private

Pointer to the magnitude filter.

Definition at line 128 of file ImageSampler.h.

Referenced by vtkMagnitude().

Point ImageSampler::_origin
private

Origin of image.

Definition at line 144 of file ImageSampler.h.

Referenced by sample(), and setupImageSampler().

Point ImageSampler::_physical_dims
private

Physical dimensions of image.

Definition at line 150 of file ImageSampler.h.

Referenced by setupImageSampler().

vtkSmartPointer<vtkImageShiftScale> ImageSampler::_shift_scale_filter
private

Pointer to the shift and scaling filter.

Definition at line 125 of file ImageSampler.h.

Referenced by vtkShiftAndScale().

int FileRangeBuilder::_status
protectedinherited
std::vector<double> ImageSampler::_voxel
private

Physical pixel size.

Definition at line 153 of file ImageSampler.h.

Referenced by sample(), and setupImageSampler().


The documentation for this class was generated from the following files: