summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/readpix.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main/readpix.c')
-rw-r--r--src/mesa/main/readpix.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/main/readpix.c b/src/mesa/main/readpix.c
index 1cb06c78a5a..25823230d62 100644
--- a/src/mesa/main/readpix.c
+++ b/src/mesa/main/readpix.c
@@ -1033,8 +1033,8 @@ _mesa_ReadnPixelsARB( GLint x, GLint y, GLsizei width, GLsizei height,
if (_mesa_is_gles(ctx)) {
if (ctx->API == API_OPENGLES2 &&
_mesa_is_color_format(format) &&
- _mesa_get_color_read_format(ctx) == format &&
- _mesa_get_color_read_type(ctx) == type) {
+ _mesa_get_color_read_format(ctx, NULL, "glReadPixels") == format &&
+ _mesa_get_color_read_type(ctx, NULL, "glReadPixels") == type) {
err = GL_NO_ERROR;
} else if (ctx->Version < 30) {
err = _mesa_es_error_check_format_and_type(ctx, format, type, 2);