VTK
vtkAbstractMapper.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkAbstractMapper.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 =========================================================================*/
28 #ifndef vtkAbstractMapper_h
29 #define vtkAbstractMapper_h
30 
31 #include "vtkRenderingCoreModule.h" // For export macro
32 #include "vtkAlgorithm.h"
33 
34 #define VTK_SCALAR_MODE_DEFAULT 0
35 #define VTK_SCALAR_MODE_USE_POINT_DATA 1
36 #define VTK_SCALAR_MODE_USE_CELL_DATA 2
37 #define VTK_SCALAR_MODE_USE_POINT_FIELD_DATA 3
38 #define VTK_SCALAR_MODE_USE_CELL_FIELD_DATA 4
39 #define VTK_SCALAR_MODE_USE_FIELD_DATA 5
40 
41 #define VTK_GET_ARRAY_BY_ID 0
42 #define VTK_GET_ARRAY_BY_NAME 1
43 
44 class vtkAbstractArray;
45 class vtkDataSet;
46 class vtkPlane;
47 class vtkPlaneCollection;
48 class vtkPlanes;
49 class vtkTimerLog;
50 class vtkWindow;
51 
52 class VTKRENDERINGCORE_EXPORT vtkAbstractMapper : public vtkAlgorithm
53 {
54 public:
56  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
57 
61  vtkMTimeType GetMTime() VTK_OVERRIDE;
62 
68  virtual void ReleaseGraphicsResources(vtkWindow *) {}
69 
71 
74  vtkGetMacro( TimeToDraw, double );
76 
78 
82  void AddClippingPlane(vtkPlane *plane);
83  void RemoveClippingPlane(vtkPlane *plane);
84  void RemoveAllClippingPlanes();
86 
88 
92  virtual void SetClippingPlanes(vtkPlaneCollection*);
93  vtkGetObjectMacro(ClippingPlanes, vtkPlaneCollection);
95 
100  void SetClippingPlanes(vtkPlanes *planes);
101 
105  void ShallowCopy(vtkAbstractMapper *m);
106 
115  static vtkDataArray *GetScalars(vtkDataSet *input, int scalarMode,
116  int arrayAccessMode, int arrayId,
117  const char *arrayName, int& cellFlag);
118 
128  static vtkAbstractArray *GetAbstractScalars(vtkDataSet *input, int scalarMode,
129  int arrayAccessMode, int arrayId,
130  const char *arrayName, int& cellFlag);
131 
132 protected:
134  ~vtkAbstractMapper() VTK_OVERRIDE;
135 
137  double TimeToDraw;
138  vtkWindow *LastWindow; // Window used for the previous render
140 
141 private:
142  vtkAbstractMapper(const vtkAbstractMapper&) VTK_DELETE_FUNCTION;
143  void operator=(const vtkAbstractMapper&) VTK_DELETE_FUNCTION;
144 };
145 
146 #endif
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:300
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
Abstract superclass for all arrays.
maintain a list of planes
implicit function for convex set of planes
Definition: vtkPlanes.h:48
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkPlaneCollection * ClippingPlanes
Timer support and logging.
Definition: vtkTimerLog.h:85
window superclass for vtkRenderWindow
Definition: vtkWindow.h:34
Superclass for all sources, filters, and sinks in VTK.
Definition: vtkAlgorithm.h:53
a simple class to control print indentation
Definition: vtkIndent.h:33
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:48
virtual vtkMTimeType GetMTime()
Return this object's modified time.
perform various plane computations
Definition: vtkPlane.h:31
abstract class specifies interface to map data