VTK  9.3.20240918
vtkCellGraphicsPrimitiveMap.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
3
16#ifndef vtkCellGraphicsPrimitiveMap_h
17#define vtkCellGraphicsPrimitiveMap_h
18
19#include "vtkObject.h"
20
21#include "vtkRenderingCoreModule.h" // For export macro
22#include "vtkSmartPointer.h" // For vtkSmartPointer
23#include "vtkTypeInt32Array.h" // For PrimitiveDescriptor::[PrimitiveToCell, VertexIDs]
24#include "vtkTypeUInt8Array.h" // For PrimitiveDescriptor::EdgeArray
25
26VTK_ABI_NAMESPACE_BEGIN
27class vtkPolyData;
28class VTKRENDERINGCORE_EXPORT vtkCellGraphicsPrimitiveMap : vtkObject
29{
30public:
33 void PrintSelf(ostream& os, vtkIndent indent) override;
34
36 {
37 vtkIdType CellIdOffset = 0;
38 vtkIdType EdgeValueBufferOffset = 0;
39 vtkIdType PointIdOffset = 0;
40 vtkIdType PrimitiveIdOffset = 0;
41 vtkIdType VertexIdOffset = 0;
42 friend std::ostream& operator<<(std::ostream& os, const CellTypeMapperOffsets& offsets)
43 {
44 os << "\nCellIdOffset: " << offsets.CellIdOffset << '\n'
45 << "EdgeValueBufferOffset: " << offsets.EdgeValueBufferOffset << '\n'
46 << "PointIdOffset: " << offsets.PointIdOffset << '\n'
47 << "PrimitiveIdOffset: " << offsets.PrimitiveIdOffset << '\n'
48 << "VertexIdOffset: " << offsets.VertexIdOffset << '\n';
49 return os;
50 }
51 };
52
54 {
58 int PrimitiveSize = 0;
59 vtkTypeInt32 LocalCellIdOffset = 0;
60 };
70
71protected:
74
75private:
77 void operator=(const vtkCellGraphicsPrimitiveMap&) = delete;
78};
79
80VTK_ABI_NAMESPACE_END
81#endif
Maps cell connectivity and offsets from VTK data model into primitives that graphics libraries expect...
static vtkCellGraphicsPrimitiveMap * New()
static PrimitiveDescriptor ProcessStrips(vtkPolyData *mesh)
break down (into triangles) and tag strips with their vtk cell id.
static PrimitiveDescriptor ProcessPolygons(vtkPolyData *mesh)
break down (into triangles) and tag polygons with their vtk cell id.
static PrimitiveDescriptor ProcessLines(vtkPolyData *mesh)
break down and tag lines with their vtk cell id.
static PrimitiveDescriptor ProcessVertices(vtkPolyData *mesh)
break down and tag vertices with their vtk cell id.
~vtkCellGraphicsPrimitiveMap() override
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
a simple class to control print indentation
Definition vtkIndent.h:108
abstract base class for most VTK objects
Definition vtkObject.h:162
concrete dataset represents vertices, lines, polygons, and triangle strips
Hold a reference to a vtkObjectBase instance.
friend std::ostream & operator<<(std::ostream &os, const CellTypeMapperOffsets &offsets)
int vtkIdType
Definition vtkType.h:315