diff options
Diffstat (limited to 'src/gui/painting/qplatformbackingstore.h')
-rw-r--r-- | src/gui/painting/qplatformbackingstore.h | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/src/gui/painting/qplatformbackingstore.h b/src/gui/painting/qplatformbackingstore.h index 1b19b2c379..a662a2290b 100644 --- a/src/gui/painting/qplatformbackingstore.h +++ b/src/gui/painting/qplatformbackingstore.h @@ -52,9 +52,11 @@ // #include <QtCore/qrect.h> +#include <QtCore/qobject.h> #include <QtGui/qwindow.h> #include <QtGui/qregion.h> +#include <QtGui/qopengl.h> QT_BEGIN_NAMESPACE @@ -65,6 +67,31 @@ class QPoint; class QImage; class QPlatformBackingStorePrivate; class QPlatformWindow; +class QPlatformTextureList; +class QPlatformTextureListPrivate; +class QOpenGLContext; + +#ifndef QT_NO_OPENGL +class Q_GUI_EXPORT QPlatformTextureList : public QObject +{ + Q_OBJECT + Q_DECLARE_PRIVATE(QPlatformTextureList) +public: + explicit QPlatformTextureList(QObject *parent = 0); + ~QPlatformTextureList(); + + int count() const; + GLuint textureId(int index) const; + QRect geometry(int index) const; + void lock(bool on); + bool isLocked() const; + + void appendTexture(GLuint textureId, const QRect &geometry); + + Q_SIGNALS: + void locked(bool); +}; +#endif class Q_GUI_EXPORT QPlatformBackingStore { @@ -79,6 +106,11 @@ public: // 'window' can be a child window, in which case 'region' is in child window coordinates and // offset is the (child) window's offset in relation to the window surface. virtual void flush(QWindow *window, const QRegion ®ion, const QPoint &offset) = 0; +#ifndef QT_NO_OPENGL + virtual void composeAndFlush(QWindow *window, const QRegion ®ion, const QPoint &offset, QPlatformTextureList *textures, QOpenGLContext *context); + virtual QImage toImage() const; + virtual GLuint toTexture(const QRegion &dirtyRegion) const; +#endif virtual void resize(const QSize &size, const QRegion &staticContents) = 0; |