Commit 67b2a548 authored by Matthias Möller's avatar Matthias Möller
Browse files

fix screenshot buffer creation (fixes screenshot with multiple instances of OF)

refs #2361

git-svn-id: 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 02c3c55d
......@@ -2265,13 +2265,14 @@ void glViewer::snapshot(QImage& _image, int _width, int _height, bool _alpha, bo
// 16 samples per pixel as we want a nice snapshot. If this is not supported
// it will fall back to the maximal supported number of samples
QFramebufferObject fb(w,h,format);
if ( fb.isValid() ){
const GLuint prevFbo = ACG::GLState::getFramebufferDraw();
ACG::GLState::bindFramebuffer(GL_FRAMEBUFFER_EXT, fb.handle());
// Turn alpha on if demanded
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment