VTK  9.2.6
vtkMultiBlockUnstructuredGridVolumeMapper.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkMultiBlockUnstructuredGridVolumeMapper.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 =========================================================================*/
20 #ifndef vtkMultiBlockUnstructuredGridVolumeMapper_h
21 #define vtkMultiBlockUnstructuredGridVolumeMapper_h
22 
23 #include <vector> // For DataBlocks
24 
25 #include "vtkNew.h" // for ivars
26 #include "vtkRenderingVolumeOpenGL2Module.h" // For export macro
28 
29 class vtkDataObjectTree;
30 class vtkDataSet;
31 class vtkMatrix4x4;
34 class vtkRenderWindow;
36 
37 class VTKRENDERINGVOLUMEOPENGL2_EXPORT vtkMultiBlockUnstructuredGridVolumeMapper
39 {
40 public:
43  void PrintSelf(ostream& os, vtkIndent indent) override;
44 
46 
50  double* GetBounds() override;
52 
53  void SelectScalarArray(int arrayNum) override;
54  void SelectScalarArray(char const* arrayName) override;
55  void SetScalarMode(int ScalarMode) override;
56  void SetArrayAccessMode(int accessMode) override;
57 
64  void Render(vtkRenderer* ren, vtkVolume* vol) override;
65 
70  void ReleaseGraphicsResources(vtkWindow* window) override;
72 
74 
79  void SetUseFloatingPointFrameBuffer(bool use);
80  vtkGetMacro(UseFloatingPointFrameBuffer, bool);
81 
83 
87  void SetBlendMode(int mode) override;
89 
90 protected:
93 
101  int FillInputPortInformation(int port, vtkInformation* info) override;
102 
104 
108 
109 private:
115  void LoadDataSet();
116 
125  void CreateMappers(vtkDataObjectTree* input);
126 
127  vtkDataObjectTree* GetDataObjectTreeInput();
128 
132  void ComputeBounds();
133 
137  void SortMappers(vtkRenderer* ren, vtkMatrix4x4* volumeMat);
138 
139  void ClearMappers();
140 
144  vtkProjectedTetrahedraMapper* CreateMapper();
145 
148  void operator=(const vtkMultiBlockUnstructuredGridVolumeMapper&) = delete;
149 
151 
152  typedef std::vector<vtkProjectedTetrahedraMapper*> MapperVec;
153  MapperVec Mappers;
154 
155  vtkMTimeType BlockLoadingTime;
156  vtkMTimeType BoundsComputeTime;
157 };
158 #endif
represents a volume (data & properties) in a rendered scene
Definition: vtkVolume.h:50
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
represent and manipulate 4x4 transformation matrices
Definition: vtkMatrix4x4.h:41
provides implementation for most abstract methods in the superclass vtkCompositeDataSet ...
Store vtkAlgorithm input/output information.
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:287
abstract class to specify dataset behavior
Definition: vtkDataSet.h:62
int FillInputPortInformation(int, vtkInformation *) override
Fill the input port information objects for this algorithm.
abstract specification for renderers
Definition: vtkRenderer.h:72
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...
Mapper to render volumes defined as vtkMultiBlockDataSet.
virtual void SetScalarMode(int)
Control how the mapper works with scalar point data and cell attribute data.
void ReleaseGraphicsResources(vtkWindow *) override
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE Release any graphics resources that are being...
virtual void SetBlendMode(int)
virtual void SetArrayAccessMode(int)
Control how the mapper works with scalar point data and cell attribute data.
window superclass for vtkRenderWindow
Definition: vtkWindow.h:38
a simple class to control print indentation
Definition: vtkIndent.h:39
Unstructured grid volume renderer.
Abstract class for an unstructured grid volume mapper.
dataset represents arbitrary combinations of all possible cell types
double * GetBounds() override
Return bounding box (array of six doubles) of data expressed as (xmin,xmax, ymin,ymax, zmin,zmax).
create a window for renderers to draw into
Composite dataset that organizes datasets into blocks.
static vtkAlgorithm * New()
virtual void SelectScalarArray(int arrayNum)
When ScalarMode is set to UsePointFieldData or UseCellFieldData, you can specify which scalar array t...