VTK  9.2.6
vtkVolumeMapper.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkVolumeMapper.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=========================================================================*/
24
25#ifndef vtkVolumeMapper_h
26#define vtkVolumeMapper_h
27
29#include "vtkRenderingVolumeModule.h" // For export macro
30
31class vtkImageData;
33class vtkRenderer;
34class vtkVolume;
35
36#define VTK_CROP_SUBVOLUME 0x0002000
37#define VTK_CROP_FENCE 0x2ebfeba
38#define VTK_CROP_INVERTED_FENCE 0x5140145
39#define VTK_CROP_CROSS 0x0417410
40#define VTK_CROP_INVERTED_CROSS 0x7be8bef
41
42class vtkWindow;
43
44class VTKRENDERINGVOLUME_EXPORT vtkVolumeMapper : public vtkAbstractVolumeMapper
45{
46public:
48 void PrintSelf(ostream& os, vtkIndent indent) override;
49
51
54 virtual void SetInputData(vtkImageData*);
55 virtual void SetInputData(vtkDataSet*);
57 virtual vtkDataSet* GetInput();
58 virtual vtkDataSet* GetInput(const int port);
60
62
104 vtkSetMacro(BlendMode, int);
121 vtkGetMacro(BlendMode, int);
123
125
133 vtkSetVector2Macro(AverageIPScalarRange, double);
134 vtkGetVectorMacro(AverageIPScalarRange, double, 2);
136
138
142 vtkSetClampMacro(Cropping, vtkTypeBool, 0, 1);
143 vtkGetMacro(Cropping, vtkTypeBool);
144 vtkBooleanMacro(Cropping, vtkTypeBool);
146
148
153 vtkSetVector6Macro(CroppingRegionPlanes, double);
154 vtkGetVectorMacro(CroppingRegionPlanes, double, 6);
156
158
162 vtkGetVectorMacro(VoxelCroppingRegionPlanes, double, 6);
164
166
177 vtkSetMacro(ComputeNormalFromOpacity, bool);
178 vtkGetMacro(ComputeNormalFromOpacity, bool);
179 vtkBooleanMacro(ComputeNormalFromOpacity, bool);
181
183
194 vtkSetClampMacro(CroppingRegionFlags, int, 0x0, 0x7ffffff);
195 vtkGetMacro(CroppingRegionFlags, int);
207
208
214 void Render(vtkRenderer* ren, vtkVolume* vol) override = 0;
215
223
276
277protected:
280
286 double SpacingAdjustedSampleDistance(double inputSpacing[3], int inputExtent[6]);
287
289
294
299
301
311
313
314private:
315 vtkVolumeMapper(const vtkVolumeMapper&) = delete;
316 void operator=(const vtkVolumeMapper&) = delete;
317};
318
319#endif
abstract class to specify dataset behavior
Definition vtkDataSet.h:57
topologically and geometrically regular array of data
a simple class to control print indentation
Definition vtkIndent.h:34
Store vtkAlgorithm input/output information.
a dataset that is topologically regular with variable spacing in the three coordinate directions
abstract specification for renderers
Definition vtkRenderer.h:67
double SpacingAdjustedSampleDistance(double inputSpacing[3], int inputExtent[6])
Compute a sample distance from the data spacing.
void Render(vtkRenderer *ren, vtkVolume *vol) override=0
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THIS METHOD OUTSIDE OF THE RENDERI...
void ConvertCroppingRegionPlanesToVoxels()
Cropping variables, and a method for converting the world coordinate cropping region planes to voxel ...
void SetCroppingRegionFlagsToInvertedFence()
Set the flags for the cropping regions.
virtual void SetInputData(vtkDataSet *)
Set/Get the input data.
virtual void SetCroppingRegionFlags(int)
Set the flags for the cropping regions.
virtual void SetInputData(vtkImageData *)
Set/Get the input data.
void SetBlendModeToSlice()
Set/Get the blend mode.
virtual vtkDataSet * GetInput(const int port)
Set/Get the input data.
void SetCroppingRegionFlagsToFence()
Set the flags for the cropping regions.
void SetCroppingRegionFlagsToInvertedCross()
Set the flags for the cropping regions.
void SetBlendModeToMinimumIntensity()
Set/Get the blend mode.
void SetBlendModeToAdditive()
Set/Get the blend mode.
int FillInputPortInformation(int, vtkInformation *) override
Fill the input port information objects for this algorithm.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void ReleaseGraphicsResources(vtkWindow *) override
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE Release any graphics resources that are being...
virtual void SetBlendMode(int)
Set/Get the blend mode.
void SetBlendModeToMaximumIntensity()
Set/Get the blend mode.
virtual vtkDataSet * GetInput()
Set/Get the input data.
void SetBlendModeToIsoSurface()
Set/Get the blend mode.
bool ComputeNormalFromOpacity
Is the normal for volume shading computed from opacity or from scalars.
double CroppingRegionPlanes[6]
Cropping variables, and a method for converting the world coordinate cropping region planes to voxel ...
double AverageIPScalarRange[2]
Threshold range for average intensity projection.
void SetCroppingRegionFlagsToCross()
Set the flags for the cropping regions.
BlendModes
Blend modes.
~vtkVolumeMapper() override
void SetBlendModeToComposite()
Set/Get the blend mode.
void SetCroppingRegionFlagsToSubVolume()
Set the flags for the cropping regions.
void SetBlendModeToAverageIntensity()
Set/Get the blend mode.
vtkTypeBool Cropping
Cropping variables, and a method for converting the world coordinate cropping region planes to voxel ...
double VoxelCroppingRegionPlanes[6]
Cropping variables, and a method for converting the world coordinate cropping region planes to voxel ...
int CroppingRegionFlags
Cropping variables, and a method for converting the world coordinate cropping region planes to voxel ...
virtual void SetInputData(vtkRectilinearGrid *)
Set/Get the input data.
represents a volume (data & properties) in a rendered scene
Definition vtkVolume.h:45
window superclass for vtkRenderWindow
Definition vtkWindow.h:39
int vtkTypeBool
Definition vtkABI.h:69
#define VTK_CROP_INVERTED_FENCE
#define VTK_CROP_FENCE
#define VTK_CROP_SUBVOLUME
#define VTK_CROP_INVERTED_CROSS
#define VTK_CROP_CROSS