summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/common/meta_blit.c
diff options
context:
space:
mode:
authorNeil Roberts <[email protected]>2014-08-04 20:54:03 +0100
committerNeil Roberts <[email protected]>2014-08-05 14:48:15 +0100
commit816dbdb106dd1955d7db90084790af21fc496d83 (patch)
tree59fd5b23f1bf3ab9026fc20268e526230d452e5f /src/mesa/drivers/common/meta_blit.c
parentafcf5d33cfd01a85dbd0adc930a1f4b137beaf95 (diff)
meta: Disable dithering during glBlitFramebuffer
According to the GL spec the only fragment operations that should affect glBlitFramebuffer are “the pixel ownership test, the scissor test, and sRGB conversion”. That implies that dithering should not be performed so we need to disable it when implementing the blit with a render. Before commit 05b52efbc97731 the dithering state would be left as whatever the application picks (the default being GL_TRUE) and after that commit it was explicitly enabled. Neither of these were correct. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=81828 Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Topi Pohjolainen <[email protected]>
Diffstat (limited to 'src/mesa/drivers/common/meta_blit.c')
-rw-r--r--src/mesa/drivers/common/meta_blit.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mesa/drivers/common/meta_blit.c b/src/mesa/drivers/common/meta_blit.c
index 31c88e16b6f..955e73f57ca 100644
--- a/src/mesa/drivers/common/meta_blit.c
+++ b/src/mesa/drivers/common/meta_blit.c
@@ -709,6 +709,9 @@ _mesa_meta_BlitFramebuffer(struct gl_context *ctx,
*/
_mesa_meta_begin(ctx, MESA_META_ALL & ~MESA_META_DRAW_BUFFERS);
+ /* Dithering shouldn't be performed for glBlitFramebuffer */
+ _mesa_set_enable(ctx, GL_DITHER, GL_FALSE);
+
/* If the clipping earlier changed the destination rect at all, then
* enable the scissor to clip to it.
*/