5 #ifndef BALL_VIEW_RENDERING_GLRENDERWINDOW_H
6 #define BALL_VIEW_RENDERING_GLRENDERWINDOW_H
8 #ifndef BALL_COMMON_GLOBAL_H
12 #ifndef BALL_DATATYPE_STRING_H
16 #ifndef BALL_VIEW_RENDERING_RENDERWINDOW_H
20 #ifndef BALL_VIEW_DATATYPE_COLORRGBA_H
24 #ifndef BALL_SYSTEM_MUTEX_H
28 #include <QtOpenGL/qgl.h>
51 virtual bool resize(
const unsigned int width,
const unsigned int height);
52 virtual void refresh();
55 virtual void renderText(
int x,
int y,
const String& text,
const ColorRGBA& color,
Size size = 16);
57 virtual void renderText(
float x,
float y,
float z,
const String& text,
const ColorRGBA& color,
Size size = 16);
63 void unlockGLContext();
70 {down_sampling_factor_ = dsfactor;}
74 {stereo_delta_ = delta;}
76 void setupStereo(
float eye_separation,
float focal_length);
79 void safeBufferSwap();
83 {
return down_sampling_factor_;}
94 virtual void customEvent(
QEvent* evt);
96 void paintEvent(QPaintEvent* e);
110 void createTexture(
const unsigned int winWidth,
const unsigned int winHeight);
111 void deleteTexture();
115 bool errorInGL(GLenum& error);
116 String getGLErrorString(GLenum error);
128 #endif // BALL_VIEW_RENDERING_GLRENDERWINDOW_H