summaryrefslogtreecommitdiff
path: root/src/render/backend/renderer.cpp
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2016-09-23 09:33:53 +0200
committerLiang Qi <liang.qi@qt.io>2016-09-23 09:33:53 +0200
commitec2c6c0f13004bc1bba92f14443228778da287a0 (patch)
tree5c4e2621091ad7bbd31e6ffb6a277c1aaee39b55 /src/render/backend/renderer.cpp
parent5476bc6b4b6a12c921da502c24c4e078b04dd3b3 (diff)
parent0e3d54f8d7f9be26687afebcc9f456e4cefc2357 (diff)
downloadqt3d-wip/qtquickintergration.tar.gz
Merge remote-tracking branch 'origin/5.8' into devwip/qtquickintergrationwip/particles
Change-Id: I4e1c528eb8e1c81aead51a5664635ca2becad397
Diffstat (limited to 'src/render/backend/renderer.cpp')
-rw-r--r--src/render/backend/renderer.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/render/backend/renderer.cpp b/src/render/backend/renderer.cpp
index ca60b8e33..7f53d3c99 100644
--- a/src/render/backend/renderer.cpp
+++ b/src/render/backend/renderer.cpp
@@ -919,6 +919,12 @@ Renderer::ViewSubmissionResultData Renderer::submitRenderViews(const QVector<Ren
frameElapsed = timer.elapsed();
}
+ // Bind lastBoundFBOId back. Needed also in threaded mode.
+ // lastBoundFBOId != m_graphicsContext->activeFBO() when the last FrameGraph leaf node/renderView
+ // contains RenderTargetSelector/RenderTarget
+ if (lastBoundFBOId != m_graphicsContext->activeFBO())
+ m_graphicsContext->bindFramebuffer(lastBoundFBOId);
+
// Reset state and call doneCurrent if the surface
// is valid and was actually activated
if (surface && m_graphicsContext->hasValidGLHelper()) {