Main Page | Directories | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

vtkMesaPolyDataMapper.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkMesaPolyDataMapper.h,v $
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00040 #ifndef __vtkMesaPolyDataMapper_h
00041 #define __vtkMesaPolyDataMapper_h
00042 
00043 #include "vtkPolyDataMapper.h"
00044 #include "MangleMesaInclude/gl.h"  // Needed for GLenum
00045 
00046 class vtkCellArray;
00047 class vtkPoints;
00048 class vtkProperty;
00049 class vtkRenderWindow;
00050 class vtkMesaRenderer;
00051 class vtkTimerLog;
00052 class vtkOpenGLTexture;
00053 
00054 class VTK_RENDERING_EXPORT vtkMesaPolyDataMapper : public vtkPolyDataMapper
00055 {
00056 public:
00057   static vtkMesaPolyDataMapper *New();
00058   vtkTypeRevisionMacro(vtkMesaPolyDataMapper,vtkPolyDataMapper);
00059   virtual void PrintSelf(ostream& os, vtkIndent indent);
00060 
00062   virtual void RenderPiece(vtkRenderer *ren, vtkActor *a);
00063 
00067   void ReleaseGraphicsResources(vtkWindow *);
00068 
00070   virtual int Draw(vtkRenderer *ren, vtkActor *a);
00071   
00072 protected:
00073   vtkMesaPolyDataMapper();
00074   ~vtkMesaPolyDataMapper();
00075 
00076   void DrawPoints(int idx,
00077                   vtkPoints *p, 
00078                   vtkDataArray *n,
00079                   vtkUnsignedCharArray *c,
00080                   vtkDataArray *t,
00081                   vtkIdType &cellNum,
00082                   int &noAbort,
00083                   vtkCellArray *ca,
00084                   vtkRenderer *ren);
00085   
00086   void DrawLines(int idx,
00087                  vtkPoints *p, 
00088                  vtkDataArray *n,
00089                  vtkUnsignedCharArray *c,
00090                  vtkDataArray *t,
00091                  vtkIdType &cellNum,
00092                  int &noAbort,
00093                  vtkCellArray *ca,
00094                  vtkRenderer *ren);
00095 
00096   void DrawPolygons(int idx,
00097                     vtkPoints *p, 
00098                     vtkDataArray *n,
00099                     vtkUnsignedCharArray *c,
00100                     vtkDataArray *t,
00101                     vtkIdType &cellNum,
00102                     int &noAbort,
00103                     GLenum rep,
00104                     vtkCellArray *ca,
00105                     vtkRenderer *ren);
00106 
00107   void DrawTStrips(int idx,
00108                    vtkPoints *p, 
00109                    vtkDataArray *n,
00110                    vtkUnsignedCharArray *c,
00111                    vtkDataArray *t,
00112                    vtkIdType &cellNum,
00113                    int &noAbort,
00114                    GLenum rep,
00115                    vtkCellArray *ca,
00116                    vtkRenderer *ren);
00117 
00118   vtkIdType TotalCells;
00119   int ListId;
00120   vtkOpenGLTexture* InternalColorTexture;
00121   vtkRenderWindow *RenderWindow;   // RenderWindow used for the previous render
00122 private:
00123   vtkMesaPolyDataMapper(const vtkMesaPolyDataMapper&);  // Not implemented.
00124   void operator=(const vtkMesaPolyDataMapper&);  // Not implemented.
00125 };
00126 
00127 #endif