VTK
vtkOpenGLPolyDataMapper.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkOpenGLPolyDataMapper.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 vtkOpenGLPolyDataMapper_h
29 #define vtkOpenGLPolyDataMapper_h
30 
31 #include "vtkRenderingOpenGLModule.h" // For export macro
32 #include "vtkPolyDataMapper.h"
33 
34 #include "vtkOpenGL.h" // Needed for GLenum
35 
36 class vtkCellArray;
37 class vtkPoints;
38 class vtkProperty;
39 class vtkRenderWindow;
40 class vtkOpenGLRenderer;
41 class vtkOpenGLTexture;
42 #if !defined(VTK_LEGACY_REMOVE)
43 class VTKRENDERINGOPENGL_EXPORT vtkOpenGLPolyDataMapper : public vtkPolyDataMapper
44 {
45 public:
48  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
49 
53  virtual void RenderPiece(vtkRenderer *ren, vtkActor *a);
54 
61 
65  virtual int Draw(vtkRenderer *ren, vtkActor *a);
66 
67 protected:
70 
71  void DrawPoints(int idx,
72  vtkPoints *p,
73  vtkDataArray *n,
75  vtkDataArray *t,
76  vtkIdType &cellNum,
77  int &noAbort,
78  vtkCellArray *ca,
79  vtkRenderer *ren);
80 
81  void DrawLines(int idx,
82  vtkPoints *p,
83  vtkDataArray *n,
85  vtkDataArray *t,
86  vtkIdType &cellNum,
87  int &noAbort,
88  vtkCellArray *ca,
89  vtkRenderer *ren);
90 
91  void DrawPolygons(int idx,
92  vtkPoints *p,
93  vtkDataArray *n,
95  vtkDataArray *t,
96  vtkIdType &cellNum,
97  int &noAbort,
98  GLenum rep,
99  vtkCellArray *ca,
100  vtkRenderer *ren);
101 
102  void DrawTStrips(int idx,
103  vtkPoints *p,
104  vtkDataArray *n,
106  vtkDataArray *t,
107  vtkIdType &cellNum,
108  int &noAbort,
109  GLenum rep,
110  vtkCellArray *ca,
111  vtkRenderer *ren);
112 
114  int ListId;
116 
117 private:
118  vtkOpenGLPolyDataMapper(const vtkOpenGLPolyDataMapper&) VTK_DELETE_FUNCTION;
119  void operator=(const vtkOpenGLPolyDataMapper&) VTK_DELETE_FUNCTION;
120 };
121 #endif // VTK_LEGACY_REMOVE
122 #endif
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:52
object to represent cell connectivity
Definition: vtkCellArray.h:51
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:55
a simple class to control print indentation
Definition: vtkIndent.h:40
a PolyDataMapper for the OpenGL library
virtual int Draw(vtkRenderer *ren, vtkActor *a)
Draw method for OpenGL.
void DrawTStrips(int idx, vtkPoints *p, vtkDataArray *n, vtkUnsignedCharArray *c, vtkDataArray *t, vtkIdType &cellNum, int &noAbort, GLenum rep, vtkCellArray *ca, vtkRenderer *ren)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkOpenGLTexture * InternalColorTexture
static vtkOpenGLPolyDataMapper * New()
void DrawLines(int idx, vtkPoints *p, vtkDataArray *n, vtkUnsignedCharArray *c, vtkDataArray *t, vtkIdType &cellNum, int &noAbort, vtkCellArray *ca, vtkRenderer *ren)
void ReleaseGraphicsResources(vtkWindow *)
Release any graphics resources that are being consumed by this mapper.
void DrawPolygons(int idx, vtkPoints *p, vtkDataArray *n, vtkUnsignedCharArray *c, vtkDataArray *t, vtkIdType &cellNum, int &noAbort, GLenum rep, vtkCellArray *ca, vtkRenderer *ren)
void DrawPoints(int idx, vtkPoints *p, vtkDataArray *n, vtkUnsignedCharArray *c, vtkDataArray *t, vtkIdType &cellNum, int &noAbort, vtkCellArray *ca, vtkRenderer *ren)
virtual void RenderPiece(vtkRenderer *ren, vtkActor *a)
Implement superclass render method.
OpenGL renderer.
OpenGL texture map.
represent and manipulate 3D points
Definition: vtkPoints.h:40
map vtkPolyData to graphics primitives
represent surface properties of a geometric object
Definition: vtkProperty.h:65
create a window for renderers to draw into
abstract specification for renderers
Definition: vtkRenderer.h:64
dynamic, self-adjusting array of unsigned char
window superclass for vtkRenderWindow
Definition: vtkWindow.h:35
int vtkIdType
Definition: vtkType.h:287