18 #ifndef vtkCellGridRenderRequest_h
19 #define vtkCellGridRenderRequest_h
21 #include "vtkRenderingCoreModule.h"
25 #include <unordered_map>
27 VTK_ABI_NAMESPACE_BEGIN
61 SURFACE_WITH_EDGES = EDGES | FACES,
62 ALL = VERTICES | EDGES | FACES | VOLUMES
67 void PrintSelf(ostream& os,
vtkIndent indent)
override;
82 virtual void SetActor(
vtkActor* actor);
98 virtual void SetWindow(
vtkWindow* window);
108 vtkGetMacro(ShapesToDraw,
char);
109 vtkSetClampMacro(ShapesToDraw,
char, 1, 9);
112 bool Initialize()
override;
114 bool Finalize()
override;
124 vtkGetMacro(IsReleasingResources,
bool);
125 vtkSetMacro(IsReleasingResources,
bool);
131 template <
typename StateType>
134 auto it = this->State.find(cellType);
135 if (it != this->State.end())
137 return static_cast<StateType*
>(it->second.get());
142 it = this->State.insert(std::make_pair(cellType, std::unique_ptr<BaseState>(
new StateType)))
144 return static_cast<StateType*
>(it->second.get());
158 bool IsReleasingResources{
false };
159 char ShapesToDraw{ RenderableGeometry::ALL };
160 std::unordered_map<vtkStringToken, std::unique_ptr<BaseState>>
State;
167 VTK_ABI_NAMESPACE_END
168 #endif // vtkCellGridRenderRequest_h
Perform an operation on cells in a vtkCellMetadata instance.
represents an object (geometry & properties) in a rendered scene
State used by vtkCellGridMapper during rendering.
std::unordered_map< vtkStringToken, std::unique_ptr< BaseState > > State
abstract specification for renderers
window superclass for vtkRenderWindow
a simple class to control print indentation
map a vtkCellGrid to graphics primitives.
StateType * GetState(vtkStringToken cellType, bool create=true)
Return a state object of the given type.
Represent a string by its integer hash.
RenderableGeometry
An enumeration of which shapes to render.