VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkAbstractContextBufferId.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 00037 #ifndef vtkAbstractContextBufferId_h 00038 #define vtkAbstractContextBufferId_h 00039 00040 #include "vtkRenderingContext2DModule.h" // For export macro 00041 #include "vtkObject.h" 00042 00043 class vtkRenderWindow; 00044 00045 class VTKRENDERINGCONTEXT2D_EXPORT vtkAbstractContextBufferId : public vtkObject 00046 { 00047 public: 00048 vtkTypeMacro(vtkAbstractContextBufferId, vtkObject); 00049 virtual void PrintSelf(ostream &os, vtkIndent indent); 00050 00051 static vtkAbstractContextBufferId * New(); 00052 00054 00055 vtkGetMacro(Width,int); 00057 00059 00060 vtkSetMacro(Width,int); 00062 00064 00065 vtkGetMacro(Height,int); 00067 00069 00070 vtkSetMacro(Height,int); 00072 00074 00075 virtual void SetContext(vtkRenderWindow *context) = 0; 00076 virtual vtkRenderWindow *GetContext() = 0; 00078 00081 virtual bool IsSupported() = 0; 00082 00085 virtual void Allocate()=0; 00086 00088 virtual bool IsAllocated() const=0; 00089 00091 00094 virtual void SetValues(int srcXmin, 00095 int srcYmin)=0; 00097 00102 virtual vtkIdType GetPickedItem(int x, int y)=0; 00103 00106 virtual void ReleaseGraphicsResources(); 00107 00108 protected: 00109 vtkAbstractContextBufferId(); 00110 virtual ~vtkAbstractContextBufferId(); 00111 00112 int Width; 00113 int Height; 00114 00115 private: 00116 vtkAbstractContextBufferId(const vtkAbstractContextBufferId &); // Not implemented. 00117 void operator=(const vtkAbstractContextBufferId &); // Not implemented. 00118 }; 00119 00120 #endif // #ifndef vtkAbstractContextBufferId_h