VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
vtkWindow.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkWindow.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
28 #ifndef __vtkWindow_h
29 #define __vtkWindow_h
30 
31 #include "vtkCommonCoreModule.h" // For export macro
32 #include "vtkObject.h"
33 
35 
37 {
38 public:
40  void PrintSelf(ostream& os, vtkIndent indent);
41 
43 
45  virtual void SetDisplayId(void *) = 0;
46  virtual void SetWindowId(void *) = 0;
47  virtual void SetParentId(void *) = 0;
48  virtual void *GetGenericDisplayId() = 0;
49  virtual void *GetGenericWindowId() = 0;
50  virtual void *GetGenericParentId() = 0;
51  virtual void *GetGenericContext() = 0;
52  virtual void *GetGenericDrawable() = 0;
53  virtual void SetWindowInfo(char *) = 0;
54  virtual void SetParentInfo(char *) = 0;
56 
58 
59  virtual int *GetPosition();
60  virtual void SetPosition(int,int);
61  virtual void SetPosition(int a[2]);
63 
65 
66  virtual int *GetSize();
67  virtual void SetSize(int,int);
68  virtual void SetSize(int a[2]);
70 
73  int *GetActualSize();
74 
76  virtual int *GetScreenSize() = 0;
77 
79 
80  vtkSetMacro(Mapped,int);
81  vtkGetMacro(Mapped,int);
82  vtkBooleanMacro(Mapped,int);
84 
86 
90  vtkSetMacro(Erase,int);
91  vtkGetMacro(Erase,int);
92  vtkBooleanMacro(Erase,int);
94 
96 
97  vtkSetMacro(DoubleBuffer,int);
98  vtkGetMacro(DoubleBuffer,int);
99  vtkBooleanMacro(DoubleBuffer,int);
101 
103 
104  vtkGetStringMacro(WindowName);
105  vtkSetStringMacro(WindowName);
107 
110  virtual void Render() = 0;
111 
113 
122  virtual unsigned char *GetPixelData(int x, int y, int x2, int y2,
123  int front) = 0;
124  virtual int GetPixelData(int x, int y, int x2, int y2, int front,
127 
129 
131  vtkGetMacro(DPI,int);
132  vtkSetClampMacro(DPI,int,1,3000);
134 
136 
139  vtkSetMacro(OffScreenRendering,int);
140  vtkGetMacro(OffScreenRendering,int);
141  vtkBooleanMacro(OffScreenRendering,int);
143 
146  virtual void MakeCurrent() {}
147 
149 
154  vtkSetVector2Macro(TileScale,int);
155  vtkGetVector2Macro(TileScale,int);
156  void SetTileScale(int s) {this->SetTileScale(s,s);}
157  vtkSetVector4Macro(TileViewport,double);
158  vtkGetVector4Macro(TileViewport,double);
160 
161 protected:
162  int OffScreenRendering;
163  vtkWindow();
164  ~vtkWindow();
165 
166  char *WindowName;
167  int Size[2];
168  int Position[2];
169  int Mapped;
170  int Erase;
172  int DPI;
173 
174  double TileViewport[4];
175  int TileSize[2];
176  int TileScale[2];
177 
178 private:
179  vtkWindow(const vtkWindow&); // Not implemented.
180  void operator=(const vtkWindow&); // Not implemented.
181 };
182 
183 #endif
184 
185 
GLsizei GLsizei GLenum GLenum const GLvoid * data
Definition: vtkgl.h:11339
char * WindowName
Definition: vtkWindow.h:166
abstract base class for most VTK objects
Definition: vtkObject.h:61
void SetTileScale(int s)
Definition: vtkWindow.h:156
#define VTKCOMMONCORE_EXPORT
#define vtkGetMacro(name, type)
Definition: vtkSetGet.h:83
#define vtkSetClampMacro(name, type, min, max)
Definition: vtkSetGet.h:133
#define vtkSetStringMacro(name)
Definition: vtkSetGet.h:94
GLint GLint GLint GLint GLint GLint y
Definition: vtkgl.h:11318
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:619
window superclass for vtkRenderWindow
Definition: vtkWindow.h:36
GLint GLint GLint GLint GLint x
Definition: vtkgl.h:11318
int DoubleBuffer
Definition: vtkWindow.h:171
int Erase
Definition: vtkWindow.h:170
virtual void PrintSelf(ostream &os, vtkIndent indent)
int Mapped
Definition: vtkWindow.h:169
#define vtkSetVector4Macro(name, type)
Definition: vtkSetGet.h:312
a simple class to control print indentation
Definition: vtkIndent.h:38
int OffScreenRendering
Definition: vtkWindow.h:158
#define vtkGetVector4Macro(name, type)
Definition: vtkSetGet.h:331
virtual void MakeCurrent()
Definition: vtkWindow.h:146
#define vtkGetStringMacro(name)
Definition: vtkSetGet.h:120
dynamic, self-adjusting array of unsigned char
GLboolean GLboolean GLboolean GLboolean a
Definition: vtkgl.h:12312
#define vtkGetVector2Macro(name, type)
Definition: vtkSetGet.h:260
GLdouble s
Definition: vtkgl.h:11594
#define vtkBooleanMacro(name, type)
Definition: vtkSetGet.h:234
#define vtkSetVector2Macro(name, type)
Definition: vtkSetGet.h:244
#define vtkSetMacro(name, type)
Definition: vtkSetGet.h:69