cogl debug: Adds glViewport call tracing

To aid in the debugging of Clutter stage resize issues this adds a
COGL_DEBUG=opengl option that will trace "some select OpenGL calls"
(currently just glViewport calls)
This commit is contained in:
Robert Bragg
2010-02-17 18:45:08 +00:00
parent 5751e48756
commit f9fe4526eb
3 changed files with 10 additions and 1 deletions

View File

@@ -681,6 +681,12 @@ _cogl_framebuffer_flush_state (CoglHandle handle,
gl_viewport_y = framebuffer->height -
(framebuffer->viewport_y + framebuffer->viewport_height);
COGL_NOTE (OPENGL, "Calling glViewport(%d, %d, %d, %d)",
framebuffer->viewport_x,
gl_viewport_y,
framebuffer->viewport_width,
framebuffer->viewport_height);
GE (glViewport (framebuffer->viewport_x,
gl_viewport_y,
framebuffer->viewport_width,