VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkOpenGL2ContextDevice2D.h 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 =========================================================================*/ 00015 00033 #ifndef vtkOpenGL2ContextDevice2D_h 00034 #define vtkOpenGL2ContextDevice2D_h 00035 00036 #include "vtkOpenGLContextDevice2D.h" 00037 00038 class VTKRENDERINGCONTEXTOPENGL2_EXPORT vtkOpenGL2ContextDevice2D : 00039 public vtkOpenGLContextDevice2D 00040 { 00041 public: 00042 vtkTypeMacro(vtkOpenGL2ContextDevice2D, vtkOpenGLContextDevice2D); 00043 virtual void PrintSelf(ostream &os, vtkIndent indent); 00044 00046 static vtkOpenGL2ContextDevice2D *New(); 00047 00049 static bool IsSupported(vtkViewport *viewport); 00050 00052 00056 virtual void DrawPointSprites(vtkImageData *sprite, float *points, int n, 00057 unsigned char* colors = 0, int nc_comps = 0); 00059 00062 virtual void DrawImage(float p[2], float scale, vtkImageData *image); 00063 00067 void DrawImage(const vtkRectf& pos, vtkImageData *image); 00068 00072 virtual void ReleaseGraphicsResources(vtkWindow *window); 00073 00074 protected: 00075 vtkOpenGL2ContextDevice2D(); 00076 virtual ~vtkOpenGL2ContextDevice2D(); 00077 00078 private: 00079 vtkOpenGL2ContextDevice2D(const vtkOpenGL2ContextDevice2D &); // Not implemented. 00080 void operator=(const vtkOpenGL2ContextDevice2D &); // Not implemented. 00081 }; 00082 00083 #endif //vtkOpenGL2ContextDevice2D_h