From dc5130ac01c8d485fce79e863a1fafbb67a6056e Mon Sep 17 00:00:00 2001 From: Daniel van Vugt Date: Tue, 6 Sep 2022 18:00:49 +0800 Subject: [PATCH] cogl: Don't check glGetError for functions that don't return errors This will at least make debug builds a tiny bit faster. Part-of: --- cogl/cogl/driver/gl/cogl-framebuffer-gl.c | 4 ++-- cogl/cogl/driver/gl/cogl-util-gl.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cogl/cogl/driver/gl/cogl-framebuffer-gl.c b/cogl/cogl/driver/gl/cogl-framebuffer-gl.c index de5ed30d9..dfd9b9913 100644 --- a/cogl/cogl/driver/gl/cogl-framebuffer-gl.c +++ b/cogl/cogl/driver/gl/cogl-framebuffer-gl.c @@ -305,7 +305,7 @@ cogl_gl_framebuffer_finish (CoglFramebufferDriver *driver) { CoglContext *ctx = context_from_driver (driver); - GE (ctx, glFinish ()); + ctx->glFinish (); } static void @@ -313,7 +313,7 @@ cogl_gl_framebuffer_flush (CoglFramebufferDriver *driver) { CoglContext *ctx = context_from_driver (driver); - GE (ctx, glFlush ()); + ctx->glFlush (); } static void diff --git a/cogl/cogl/driver/gl/cogl-util-gl.c b/cogl/cogl/driver/gl/cogl-util-gl.c index 32ecbd3c3..ed5ee2525 100644 --- a/cogl/cogl/driver/gl/cogl-util-gl.c +++ b/cogl/cogl/driver/gl/cogl-util-gl.c @@ -526,7 +526,7 @@ cogl_gl_create_timestamp_query (CoglContext *context) * the timestamp query being placed at the point of glGetQueryObject much * later, resulting in a GPU timestamp much later on in time. */ - GE (context, glFlush ()); + context->glFlush (); return query; }