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:
46  static vtkOpenGLPolyDataMapper *New();
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
vtkPolyDataMapper
map vtkPolyData to graphics primitives
Definition: vtkPolyDataMapper.h:42
vtkPoints
represent and manipulate 3D points
Definition: vtkPoints.h:39
vtkMapper::ReleaseGraphicsResources
virtual void ReleaseGraphicsResources(vtkWindow *)
Release any graphics resources that are being consumed by this mapper.
Definition: vtkMapper.h:119
vtkIdType
int vtkIdType
Definition: vtkType.h:287
vtkPolyDataMapper::RenderPiece
virtual void RenderPiece(vtkRenderer *ren, vtkActor *act)=0
Implemented by sub classes.
vtkOpenGLPolyDataMapper::InternalColorTexture
vtkOpenGLTexture * InternalColorTexture
Definition: vtkOpenGLPolyDataMapper.h:115
vtkUnsignedCharArray
dynamic, self-adjusting array of unsigned char
Definition: vtkUnsignedCharArray.h:41
vtkDataArray
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:54
vtkOpenGLPolyDataMapper::ListId
int ListId
Definition: vtkOpenGLPolyDataMapper.h:114
vtkWindow
window superclass for vtkRenderWindow
Definition: vtkWindow.h:34
vtkActor
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:51
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkCellArray
object to represent cell connectivity
Definition: vtkCellArray.h:50
vtkOpenGLRenderer
OpenGL renderer.
Definition: vtkOpenGLRenderer.h:36
vtkOpenGLPolyDataMapper::TotalCells
vtkIdType TotalCells
Definition: vtkOpenGLPolyDataMapper.h:113
vtkPolyDataMapper::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
vtkPolyDataMapper::New
static vtkPolyDataMapper * New()
vtkRenderer
abstract specification for renderers
Definition: vtkRenderer.h:63
vtkPolyDataMapper.h
vtkProperty
represent surface properties of a geometric object
Definition: vtkProperty.h:64
vtkRenderWindow
create a window for renderers to draw into
Definition: vtkRenderWindow.h:86
vtkOpenGLTexture
OpenGL texture map.
Definition: vtkOpenGLTexture.h:39
vtkOpenGLPolyDataMapper
a PolyDataMapper for the OpenGL library
Definition: vtkOpenGLPolyDataMapper.h:43
vtkOpenGL.h