vo_opengl: print error number if framebuffer creation fails

Seems like a waste not to print this.

Anyone with enough technical knowledge to have use for the exact error
can map the number back to the GL symbol, so don't bother to convert it
to a symbol.
This commit is contained in:
wm4 2014-12-02 19:59:41 +01:00
parent b6ca4a48e1
commit 33a6b8df46
1 changed files with 4 additions and 2 deletions

View File

@ -517,8 +517,10 @@ static bool fbotex_init(struct gl_video *p, struct fbotex *fbo, int w, int h,
gl->FramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
p->gl_target, fbo->texture, 0);
if (gl->CheckFramebufferStatus(GL_FRAMEBUFFER) != GL_FRAMEBUFFER_COMPLETE) {
MP_ERR(p, "Error: framebuffer completeness check failed!\n");
GLenum err = gl->CheckFramebufferStatus(GL_FRAMEBUFFER);
if (err != GL_FRAMEBUFFER_COMPLETE) {
MP_ERR(p, "Error: framebuffer completeness check failed (error=%d).\n",
(int)err);
res = false;
}