VTK  9.3.20240423
vtkAbstractMapper.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
19#ifndef vtkAbstractMapper_h
20#define vtkAbstractMapper_h
21
22#include "vtkAlgorithm.h"
23#include "vtkRenderingCoreModule.h" // For export macro
24#include "vtkWrappingHints.h" // For VTK_MARSHALMANUAL
25
26#define VTK_SCALAR_MODE_DEFAULT 0
27#define VTK_SCALAR_MODE_USE_POINT_DATA 1
28#define VTK_SCALAR_MODE_USE_CELL_DATA 2
29#define VTK_SCALAR_MODE_USE_POINT_FIELD_DATA 3
30#define VTK_SCALAR_MODE_USE_CELL_FIELD_DATA 4
31#define VTK_SCALAR_MODE_USE_FIELD_DATA 5
32
33#define VTK_GET_ARRAY_BY_ID 0
34#define VTK_GET_ARRAY_BY_NAME 1
35
36VTK_ABI_NAMESPACE_BEGIN
38class vtkDataSet;
39class vtkPlane;
41class vtkPlanes;
42class vtkTimerLog;
44class vtkWindow;
45
46class VTKRENDERINGCORE_EXPORT VTK_MARSHALMANUAL vtkAbstractMapper : public vtkAlgorithm
47{
48public:
50 void PrintSelf(ostream& os, vtkIndent indent) override;
51
56
63
65
68 vtkGetMacro(TimeToDraw, double);
70
72
80
82
87 vtkGetObjectMacro(ClippingPlanes, vtkPlaneCollection);
89
95
100
109 static vtkDataArray* GetScalars(vtkDataSet* input, int scalarMode, int arrayAccessMode,
110 int arrayId, const char* arrayName, int& cellFlag);
111
121 static vtkAbstractArray* GetAbstractScalars(vtkDataSet* input, int scalarMode,
122 int arrayAccessMode, int arrayId, const char* arrayName, int& cellFlag);
123
137 vtkDataSet* input, int scalarMode, unsigned char& ghostsToSkip);
138
143
144protected:
147
150 vtkWindow* LastWindow; // Window used for the previous render
152
153private:
154 vtkAbstractMapper(const vtkAbstractMapper&) = delete;
155 void operator=(const vtkAbstractMapper&) = delete;
156};
157
158VTK_ABI_NAMESPACE_END
159#endif
Abstract superclass for all arrays.
abstract class specifies interface to map data
virtual void ReleaseGraphicsResources(vtkWindow *)
Release any graphics resources that are being consumed by this mapper.
void RemoveAllClippingPlanes()
Specify clipping planes to be applied when the data is mapped (at most 6 clipping planes can be speci...
static vtkDataArray * GetScalars(vtkDataSet *input, int scalarMode, int arrayAccessMode, int arrayId, const char *arrayName, int &cellFlag)
Internal helper function for getting the active scalars.
vtkMTimeType GetMTime() override
Override Modifiedtime as we have added Clipping planes.
static vtkUnsignedCharArray * GetGhostArray(vtkDataSet *input, int scalarMode, unsigned char &ghostsToSkip)
Returns the ghost array associated with the corresponding scalar mode, if present.
int GetNumberOfClippingPlanes()
Get the number of clipping planes.
~vtkAbstractMapper() override
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetClippingPlanes(vtkPlanes *planes)
An alternative way to set clipping planes: use up to six planes found in the supplied instance of the...
void AddClippingPlane(vtkPlane *plane)
Specify clipping planes to be applied when the data is mapped (at most 6 clipping planes can be speci...
virtual void ShallowCopy(vtkAbstractMapper *m)
Make a shallow copy of this mapper.
vtkPlaneCollection * ClippingPlanes
static vtkAbstractArray * GetAbstractScalars(vtkDataSet *input, int scalarMode, int arrayAccessMode, int arrayId, const char *arrayName, int &cellFlag)
Internal helper function for getting the active scalars as an abstract array.
virtual void SetClippingPlanes(vtkPlaneCollection *)
Get/Set the vtkPlaneCollection which specifies the clipping planes.
void RemoveClippingPlane(vtkPlane *plane)
Specify clipping planes to be applied when the data is mapped (at most 6 clipping planes can be speci...
Superclass for all sources, filters, and sinks in VTK.
abstract superclass for arrays of numeric data
abstract class to specify dataset behavior
Definition vtkDataSet.h:166
a simple class to control print indentation
Definition vtkIndent.h:108
maintain a list of planes
perform various plane computations
Definition vtkPlane.h:135
implicit function for convex set of planes
Definition vtkPlanes.h:151
Timer support and logging.
dynamic, self-adjusting array of unsigned char
window superclass for vtkRenderWindow
Definition vtkWindow.h:48
vtkTypeUInt32 vtkMTimeType
Definition vtkType.h:270
#define VTK_MARSHALMANUAL