summaryrefslogtreecommitdiffstats
path: root/src/gui/opengl/qopenglframebufferobject_p.h
diff options
context:
space:
mode:
authorSamuel Rødal <samuel.rodal@nokia.com>2012-02-14 19:43:46 +0100
committerQt by Nokia <qt-info@nokia.com>2012-02-15 17:01:50 +0100
commitb36ece3ff4ee516eab8f0f34c8e7f54d2fcee311 (patch)
tree432b03015991a752012d781558020751708b12d6 /src/gui/opengl/qopenglframebufferobject_p.h
parent0f0d8a5a8fecf545cdf58ab50d05253ffd20e90b (diff)
Added support for resetting QOpenGLFramebufferObject attachments.
As the documentation says, this can be useful to free or recreate attachments when needed. For example, it might be useful to free stencil and depth attachments to free up resources when not rendering to the framebuffer object. Change-Id: Ib267024fdd380a788c256eb8fb86e0f8832329e0 Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
Diffstat (limited to 'src/gui/opengl/qopenglframebufferobject_p.h')
-rw-r--r--src/gui/opengl/qopenglframebufferobject_p.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gui/opengl/qopenglframebufferobject_p.h b/src/gui/opengl/qopenglframebufferobject_p.h
index 78d9d93ffe..23cab8f0af 100644
--- a/src/gui/opengl/qopenglframebufferobject_p.h
+++ b/src/gui/opengl/qopenglframebufferobject_p.h
@@ -120,7 +120,9 @@ public:
QOpenGLFramebufferObject::Attachment attachment,
GLenum internal_format, GLenum texture_target,
GLint samples = 0, bool mipmap = false);
- bool checkFramebufferStatus() const;
+ void initAttachments(QOpenGLContext *ctx, QOpenGLFramebufferObject::Attachment attachment);
+
+ bool checkFramebufferStatus(QOpenGLContext *ctx) const;
QOpenGLSharedResourceGuard *fbo_guard;
QOpenGLSharedResourceGuard *texture_guard;
QOpenGLSharedResourceGuard *depth_buffer_guard;