00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00028 #ifndef __vtkWindow_h
00029 #define __vtkWindow_h
00030
00031 #include "vtkObject.h"
00032
00033 class vtkUnsignedCharArray;
00034
00035 class VTK_COMMON_EXPORT vtkWindow : public vtkObject
00036 {
00037 public:
00038 vtkTypeRevisionMacro(vtkWindow,vtkObject);
00039 void PrintSelf(ostream& os, vtkIndent indent);
00040
00042
00044 virtual void SetDisplayId(void *) = 0;
00045 virtual void SetWindowId(void *) = 0;
00046 virtual void SetParentId(void *) = 0;
00047 virtual void *GetGenericDisplayId() = 0;
00048 virtual void *GetGenericWindowId() = 0;
00049 virtual void *GetGenericParentId() = 0;
00050 virtual void *GetGenericContext() = 0;
00051 virtual void *GetGenericDrawable() = 0;
00052 virtual void SetWindowInfo(char *) = 0;
00053 virtual void SetParentInfo(char *) = 0;
00055
00057
00058 virtual int *GetPosition();
00059 virtual void SetPosition(int,int);
00060 virtual void SetPosition(int a[2]);
00062
00064
00065 virtual int *GetSize();
00066 virtual void SetSize(int,int);
00067 virtual void SetSize(int a[2]);
00069
00071 virtual int *GetScreenSize() = 0;
00072
00074
00075 vtkSetMacro(Mapped,int);
00076 vtkGetMacro(Mapped,int);
00077 vtkBooleanMacro(Mapped,int);
00079
00081
00085 vtkSetMacro(Erase,int);
00086 vtkGetMacro(Erase,int);
00087 vtkBooleanMacro(Erase,int);
00089
00091
00092 vtkSetMacro(DoubleBuffer,int);
00093 vtkGetMacro(DoubleBuffer,int);
00094 vtkBooleanMacro(DoubleBuffer,int);
00096
00098
00099 vtkGetStringMacro(WindowName);
00100 virtual void SetWindowName(const char *);
00102
00105 virtual void Render() = 0;
00106
00108
00116 virtual unsigned char *GetPixelData(int, int, int, int, int) = 0;
00117 virtual int GetPixelData(int ,int ,int ,int , int,
00118 vtkUnsignedCharArray*) = 0;
00120
00122
00124 vtkGetMacro(DPI,int);
00125 vtkSetClampMacro(DPI,int,1,3000);
00127
00129
00132 vtkSetMacro(OffScreenRendering,int);
00133 vtkGetMacro(OffScreenRendering,int);
00134 vtkBooleanMacro(OffScreenRendering,int);
00136
00139 virtual void MakeCurrent() {};
00140
00142
00147 vtkSetVector2Macro(TileScale,int);
00148 vtkGetVector2Macro(TileScale,int);
00149 void SetTileScale(int s) {this->SetTileScale(s,s);}
00150 vtkSetVector4Macro(TileViewport,double);
00151 vtkGetVector4Macro(TileViewport,double);
00153
00154 protected:
00155 int OffScreenRendering;
00156 vtkWindow();
00157 ~vtkWindow();
00158
00159 char *WindowName;
00160 int Size[2];
00161 int Position[2];
00162 int Mapped;
00163 int Erase;
00164 int DoubleBuffer;
00165 int DPI;
00166
00167 double TileViewport[4];
00168 int TileSize[2];
00169 int TileScale[2];
00170
00171 private:
00172 vtkWindow(const vtkWindow&);
00173 void operator=(const vtkWindow&);
00174 };
00175
00176 #endif
00177
00178