Module: Mesa Branch: master Commit: f86d7af4a0003997890edc84158e72c21c11037e URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=f86d7af4a0003997890edc84158e72c21c11037e
Author: Brian Paul <[email protected]> Date: Tue Apr 20 16:12:34 2010 -0600 mesa: raise GL_INVALID_OPERATION for glReadPixels(GL_COLOR_INDEX) We no longer support CI-mode color buffers so this is always an error. --- src/mesa/main/readpix.c | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/src/mesa/main/readpix.c b/src/mesa/main/readpix.c index f4d74e8..93f2bd3 100644 --- a/src/mesa/main/readpix.c +++ b/src/mesa/main/readpix.c @@ -103,6 +103,12 @@ _mesa_error_check_format_type(GLcontext *ctx, GLenum format, GLenum type, "glReadPixels(no color buffer)"); return GL_TRUE; } + /* We no longer support CI-mode color buffers so trying to read + * GL_COLOR_INDEX pixels is always an error. + */ + _mesa_error(ctx, GL_INVALID_OPERATION, + "glReadPixels(color buffer is RGB)"); + return GL_TRUE; } break; case GL_STENCIL_INDEX: _______________________________________________ mesa-commit mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/mesa-commit
