diff options
author | marha <marha@users.sourceforge.net> | 2012-01-23 08:33:10 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-01-23 08:33:10 +0100 |
commit | 45e3694d529b052f4122262c9bdff5476219b2b4 (patch) | |
tree | 173df8f3cea2330e782626e382a90668950d3e6f /mesalib/src/mesa/main/fbobject.c | |
parent | a8ef69cc0c9e5281e6b745dd4a2be75f629eb8b8 (diff) | |
download | vcxsrv-45e3694d529b052f4122262c9bdff5476219b2b4.tar.gz vcxsrv-45e3694d529b052f4122262c9bdff5476219b2b4.tar.bz2 vcxsrv-45e3694d529b052f4122262c9bdff5476219b2b4.zip |
git update libX11 mesa libxcb xkeyboard-config 23 jan 2012
Diffstat (limited to 'mesalib/src/mesa/main/fbobject.c')
-rw-r--r-- | mesalib/src/mesa/main/fbobject.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/mesalib/src/mesa/main/fbobject.c b/mesalib/src/mesa/main/fbobject.c index 052495907..2b3ac2e25 100644 --- a/mesalib/src/mesa/main/fbobject.c +++ b/mesalib/src/mesa/main/fbobject.c @@ -2709,9 +2709,13 @@ _mesa_BlitFramebufferEXT(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, if ((readRb == NULL) || (drawRb == NULL)) { mask &= ~GL_STENCIL_BUFFER_BIT; } - else if (readRb->Format != drawRb->Format) { + else if (_mesa_get_format_bits(readRb->Format, GL_STENCIL_BITS) != + _mesa_get_format_bits(drawRb->Format, GL_STENCIL_BITS)) { + /* There is no need to check the stencil datatype here, because + * there is only one: GL_UNSIGNED_INT. + */ _mesa_error(ctx, GL_INVALID_OPERATION, - "glBlitFramebufferEXT(stencil buffer format mismatch)"); + "glBlitFramebufferEXT(stencil buffer size mismatch)"); return; } } @@ -2731,7 +2735,10 @@ _mesa_BlitFramebufferEXT(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, if ((readRb == NULL) || (drawRb == NULL)) { mask &= ~GL_DEPTH_BUFFER_BIT; } - else if (readRb->Format != drawRb->Format) { + else if ((_mesa_get_format_bits(readRb->Format, GL_DEPTH_BITS) != + _mesa_get_format_bits(drawRb->Format, GL_DEPTH_BITS)) || + (_mesa_get_format_datatype(readRb->Format) != + _mesa_get_format_datatype(drawRb->Format))) { _mesa_error(ctx, GL_INVALID_OPERATION, "glBlitFramebufferEXT(depth buffer format mismatch)"); return; |