vtkOpenGLPolyDataMapper.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00039 #ifndef __vtkOpenGLPolyDataMapper_h
00040 #define __vtkOpenGLPolyDataMapper_h
00041
00042 #include "vtkPolyDataMapper.h"
00043
00044 #if defined(__APPLE__) && (defined(VTK_USE_CARBON) || defined(VTK_USE_COCOA))
00045 #include <OpenGL/gl.h>
00046 #else
00047 #include <GL/gl.h>
00048 #endif
00049
00050 class vtkCellArray;
00051 class vtkPoints;
00052 class vtkProperty;
00053 class vtkRenderWindow;
00054 class vtkOpenGLRenderer;
00055 class vtkOpenGLTexture;
00056
00057 class VTK_RENDERING_EXPORT vtkOpenGLPolyDataMapper : public vtkPolyDataMapper
00058 {
00059 public:
00060 static vtkOpenGLPolyDataMapper *New();
00061 vtkTypeRevisionMacro(vtkOpenGLPolyDataMapper,vtkPolyDataMapper);
00062 virtual void PrintSelf(ostream& os, vtkIndent indent);
00063
00065 virtual void RenderPiece(vtkRenderer *ren, vtkActor *a);
00066
00070 void ReleaseGraphicsResources(vtkWindow *);
00071
00073 virtual int Draw(vtkRenderer *ren, vtkActor *a);
00074
00075 protected:
00076 vtkOpenGLPolyDataMapper();
00077 ~vtkOpenGLPolyDataMapper();
00078
00079 void DrawPoints(int idx,
00080 vtkPoints *p,
00081 vtkDataArray *n,
00082 vtkUnsignedCharArray *c,
00083 vtkDataArray *t,
00084 vtkIdType &cellNum,
00085 int &noAbort,
00086 vtkCellArray *ca,
00087 vtkRenderer *ren);
00088
00089 void DrawLines(int idx,
00090 vtkPoints *p,
00091 vtkDataArray *n,
00092 vtkUnsignedCharArray *c,
00093 vtkDataArray *t,
00094 vtkIdType &cellNum,
00095 int &noAbort,
00096 vtkCellArray *ca,
00097 vtkRenderer *ren);
00098
00099 void DrawPolygons(int idx,
00100 vtkPoints *p,
00101 vtkDataArray *n,
00102 vtkUnsignedCharArray *c,
00103 vtkDataArray *t,
00104 vtkIdType &cellNum,
00105 int &noAbort,
00106 GLenum rep,
00107 vtkCellArray *ca,
00108 vtkRenderer *ren);
00109
00110 void DrawTStrips(int idx,
00111 vtkPoints *p,
00112 vtkDataArray *n,
00113 vtkUnsignedCharArray *c,
00114 vtkDataArray *t,
00115 vtkIdType &cellNum,
00116 int &noAbort,
00117 GLenum rep,
00118 vtkCellArray *ca,
00119 vtkRenderer *ren);
00120
00121 vtkIdType TotalCells;
00122 int ListId;
00123 vtkOpenGLTexture* InternalColorTexture;
00124
00125 private:
00126 vtkOpenGLPolyDataMapper(const vtkOpenGLPolyDataMapper&);
00127 void operator=(const vtkOpenGLPolyDataMapper&);
00128 };
00129
00130 #endif