VTK
vtkOSOpenGLRenderWindow.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkOSOpenGLRenderWindow.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 =========================================================================*/
31 #ifndef vtkOSOpenGLRenderWindow_h
32 #define vtkOSOpenGLRenderWindow_h
33 
34 #include "vtkRenderingOpenGL2Module.h" // For export macro
35 #include "vtkOpenGLRenderWindow.h"
36 
37 class vtkIdList;
38 class vtkOSOpenGLRenderWindowInternal;
39 
40 class VTKRENDERINGOPENGL2_EXPORT vtkOSOpenGLRenderWindow : public vtkOpenGLRenderWindow
41 {
42 public:
43  static vtkOSOpenGLRenderWindow *New();
45  void PrintSelf(ostream& os, vtkIndent indent);
46 
48  virtual void Start(void);
49 
51  virtual void Frame(void);
52 
54  virtual void WindowInitialize(void);
55 
60  virtual void Initialize(void);
61 
66  virtual void Finalize(void);
67 
69  virtual void SetFullScreen(int);
70 
72 
73  virtual void SetSize(int x,int y);
74  virtual void SetSize(int a[2]) {this->SetSize(a[0], a[1]);};
76 
78  virtual int *GetScreenSize();
79 
81  virtual int *GetPosition();
82 
84 
85  void SetPosition(int x, int y);
86  void SetPosition(int a[2]) {this->SetPosition(a[0], a[1]);};
88 
93  virtual void SetStereoCapableWindow(int capable);
94 
96  void MakeCurrent();
97 
100  virtual bool IsCurrent();
101 
105  void SetForceMakeCurrent();
106 
108  const char *ReportCapabilities();
109 
111  int SupportsOpenGL();
112 
114  int IsDirect();
115 
117  virtual void WindowRemap(void);
118 
120 
121  virtual void *GetGenericDisplayId() {return 0;}
122  virtual void *GetGenericWindowId();
123  virtual void *GetGenericParentId() {return 0;}
124  virtual void *GetGenericContext();
125  virtual void *GetGenericDrawable() {return 0;}
127 
130  void SetDisplayId(void *) {}
131 
133  void SetParentId(void *);
134 
136  void SetWindowId(void *);
137 
140  void SetNextWindowId(void *);
141 
142  void SetWindowName(const char *);
143 
145 
147  void HideCursor() {}
148  void ShowCursor() {}
150 
152  virtual void SetCurrentCursor(int);
153 
157  virtual int GetEventPending();
158 
160  void SetWindowInfo(char *info);
161 
163  void SetNextWindowInfo(char *info);
164 
166  void SetParentInfo(char *info);
167 
169  void SetOffScreenRendering(int i);
170 
171 protected:
174 
175  vtkOSOpenGLRenderWindowInternal *Internal;
176 
177  int OwnWindow;
178  int OwnDisplay;
179  int ScreenSize[2];
180  int CursorHidden;
181  int ForceMakeCurrent;
182  char *Capabilities;
183 
184  void CreateAWindow();
185  void DestroyWindow();
186  void CreateOffScreenWindow(int width, int height);
187  void DestroyOffScreenWindow();
188  void ResizeOffScreenWindow(int width, int height);
189 
190 
191 private:
192  vtkOSOpenGLRenderWindow(const vtkOSOpenGLRenderWindow&); // Not implemented.
193  void operator=(const vtkOSOpenGLRenderWindow&); // Not implemented.
194 };
195 
196 
197 
198 #endif
OpenGL rendering window.
virtual void SetOffScreenRendering(int)
virtual void Finalize()=0
virtual void SetForceMakeCurrent()
virtual void SetWindowInfo(char *)=0
virtual void SetSize(int a[2])
virtual void WindowRemap()=0
virtual void * GetGenericContext()=0
void PrintSelf(ostream &os, vtkIndent indent)
static vtkRenderWindow * New()
virtual int * GetScreenSize()=0
virtual void SetWindowId(void *)=0
OffScreen Mesa rendering window.
virtual void SetCurrentCursor(int)
virtual void SetNextWindowInfo(char *)=0
virtual void SetFullScreen(int)=0
virtual int GetEventPending()=0
virtual void SetSize(int, int)
virtual void SetStereoCapableWindow(int capable)
virtual const char * ReportCapabilities()
virtual int IsDirect()
virtual int SupportsOpenGL()
virtual void SetParentInfo(char *)=0
virtual bool IsCurrent()=0
virtual void SetParentId(void *)=0
a simple class to control print indentation
Definition: vtkIndent.h:38
virtual void DestroyWindow()=0
list of point or cell ids
Definition: vtkIdList.h:35
virtual void MakeCurrent()=0
virtual void SetNextWindowId(void *)=0
virtual int * GetPosition()
virtual void Frame()=0
virtual void Start()=0
virtual void SetWindowName(const char *)
virtual void SetPosition(int, int)
virtual void CreateAWindow()=0
virtual void * GetGenericWindowId()=0