From 05097765d41b9dba7d1796e54a4f4587c37fcdf0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Fonseca?= Date: Fri, 10 May 2013 21:43:11 +0100 Subject: [PATCH] glstate: Bind the bound draw fbo for read before dumping. Otherwise we'll dump the currently bound read fbo. --- retrace/glstate_images.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/retrace/glstate_images.cpp b/retrace/glstate_images.cpp index 3f6d438..759ed59 100644 --- a/retrace/glstate_images.cpp +++ b/retrace/glstate_images.cpp @@ -1213,9 +1213,11 @@ dumpFramebuffer(JSONWriter &json, Context &context) boundDrawFbo, draw_buffer0, colorRb, depthRb, stencilRb, rbs, &numRbs); + } else { + glBindFramebuffer(GL_READ_FRAMEBUFFER, boundDrawFbo); } - dumpFramebufferAttachments(json, context, GL_DRAW_FRAMEBUFFER); + dumpFramebufferAttachments(json, context, GL_READ_FRAMEBUFFER); if (multisample) { glBindRenderbuffer(GL_RENDERBUFFER, boundRb); -- 2.43.0