With OpenGL 3.3, is it allowed/okay to bind different sized textures to a frame buffer?
I.e.
glBindFramebuffer(GL_FRAMEBUFFER, fbo);
glFramebufferTexture2D, GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, texture200x200,0);
glViewport(0,0,200,200);
/*....
some time later
... */
glBindFramebuffer(GL_FRAMEBUFFER, fbo);
glFramebufferTexture2D, GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, texture500x500,0);
glViewport(0,0,500,500);
I.e. texture200x200
is a 200x200 sized texture, and texture500x500
is 500x500, fbo
is the same framebuffer each time.
My use case is a need to render to texture several times in a frame, and each of these textures is arbitrarily sized.