diff options
author | Samuel Rødal <sroedal@trolltech.com> | 2009-04-16 08:55:12 (GMT) |
---|---|---|
committer | Samuel Rødal <sroedal@trolltech.com> | 2009-04-16 15:28:26 (GMT) |
commit | a241ebac49f01ba0e26a177f1aadbd18c7e9cae7 (patch) | |
tree | c7e577ecf60c990a1a5a1902ba0637bd3187a4d6 /src/opengl/qgl_p.h | |
parent | 1e1371e19ae62a5bf57dcad8d53ac70dcd2ad0cb (diff) | |
download | Qt-a241ebac49f01ba0e26a177f1aadbd18c7e9cae7.zip Qt-a241ebac49f01ba0e26a177f1aadbd18c7e9cae7.tar.gz Qt-a241ebac49f01ba0e26a177f1aadbd18c7e9cae7.tar.bz2 |
Use FBOs as pixmap backend in GL graphics system.
We now use FBOs to implement render-to-pixmap for the GL pixmap backend.
A multisample FBO is used for rendering, and is then blitted onto a
non-multisample FBO dynamically bound to the relevant texture.
Reviewed-by: Tom
Diffstat (limited to 'src/opengl/qgl_p.h')
-rw-r--r-- | src/opengl/qgl_p.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/opengl/qgl_p.h b/src/opengl/qgl_p.h index 8ab73d8..51c07b5 100644 --- a/src/opengl/qgl_p.h +++ b/src/opengl/qgl_p.h @@ -60,6 +60,7 @@ #include "QtCore/qthreadstorage.h" #include "QtCore/qhash.h" #include "private/qwidget_p.h" +#include "private/qpixmapdata_gl_p.h" #ifndef QT_OPENGL_ES_1_CL #define q_vertexType float @@ -238,6 +239,7 @@ public: QGLFormat glFormat; QGLFormat reqFormat; GLuint pbo; + GLuint fbo; uint valid : 1; uint sharing : 1; @@ -255,6 +257,7 @@ public: GLint max_texture_size; GLuint current_fbo; + QPaintEngine *active_engine; #ifdef Q_WS_WIN static inline QGLExtensionFuncs& qt_get_extension_funcs(const QGLContext *ctx) { return ctx->d_ptr->extensionFuncs; } @@ -289,7 +292,7 @@ class QGLWindowSurface; class QGLDrawable { public: QGLDrawable() : widget(0), buffer(0), fbo(0) - , wsurf(0) + , wsurf(0), pixmapData(0) {} void setDevice(QPaintDevice *pdev); void swapBuffers(); @@ -303,6 +306,8 @@ public: QGLContext *context() const; bool autoFillBackground() const; + QGLPixmapData *copyOnBegin() const; + private: bool wasBound; QGLWidget *widget; @@ -313,6 +318,7 @@ private: #else QGLWindowSurface *wsurf; #endif + QGLPixmapData *pixmapData; }; // GL extension definitions |