I have an offscreen framebuffer which I blit to the primary framebuffer using
glBlitFramebufferEXT(0, 0, width,height,
0, 0, windowWidth, windowHeight,
This works fine when width and height equals windowWidth and windowHeight, but if they are off by just a single pixel, then it fails with invalid operation. I am using the offscreen fbo to let the visible window rescale while keeping the offscreen rendering constant in size, so this is a big problem for me now.
I have previously been blitting from the offscreen fbo to the primary with different size and it worked just fine. After rewriting the fbo creation to multisampling (now using renderbuffers rather than textures) it has the size requirement which it didn’t have before.
glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER_EXT, 8, GL_RGBA8, width, height);
glFramebufferRenderbufferEXT(GL_FRAMEBUFFER_EXT, GL_COLOR_ATTACHMENT0_EXT, GL_RENDERBUFFER_EXT, ColorBufferID);
Is there anything in my framebuffer creation which makes it unable to rescale pixel data when blitting? According the the specks, this should work just fine, but it doesn’t. Any pointers would be greatly appresiated.
EDIT: currently primary frame buffer is non multisample while the offscreen has been anything from 0 to 16