i have error code 1286 from glError, and cant find any references to what it means.
gluErrorString returns (null)
:-/
im working with FBO’s, and clearing the framebuffer.
void TextureRender::Lock(bool clear)
{
Device::GetInstance().CheckErrors();
glBindTexture(GL_TEXTURE_2D, 0);
glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, fb);
Device::GetInstance().CheckFramebufferStatus(); // <-- checking framebuffer status here returns "unsupported format", but in my create method, this check returns okay :-/
Device::GetInstance().CheckErrors();
glPushAttrib(GL_VIEWPORT_BIT);
glViewport(0, 0, width, height);
Device::GetInstance().CheckErrors();
glClearColor(1, 0, 0, 0);
Device::GetInstance().CheckErrors(); // <-- no error till this point
if (clear)
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
Device::GetInstance().CheckErrors();// <-- error is found here
}
The error INVALID_FRAMEBUFFER_OPERATION_EXT is generated if the value of FRAMEBUFFER_STATUS_EXT is not FRAMEBUFFER_COMPLETE_EXT when any attempts to render to or read from the framebuffer are made.
Creating is not the same as binding for use.
You said yourself the check framebuffer status reports unsupported format.
What hardware and format was that?
That the error is found on the first rendering is obviously when that condition is evaluated.
Put more code or take an FBO example which works and adapt.