i965/cnl: Don't resolve single sampled color rb in case of sRGB formats
authorAnuj Phogat <anuj.phogat@gmail.com>
Thu, 27 Apr 2017 17:35:05 +0000 (10:35 -0700)
committerAnuj Phogat <anuj.phogat@gmail.com>
Fri, 9 Jun 2017 23:02:59 +0000 (16:02 -0700)
As sRGB now supports lossless compression, we also need to stop resolving
single sampled color render buffers for sRGB formats in Gen 10.

Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/mesa/drivers/dri/i965/intel_mipmap_tree.c

index 7b4cb12ac68d813afaffd0a7f63d2b9addd9e4c9..eda8a0afab537ee371e31cec41dcd4e9cf717470 100644 (file)
@@ -2582,7 +2582,7 @@ intel_miptree_prepare_render(struct brw_context *brw,
     * enabled because otherwise the surface state will be programmed with
     * the linear equivalent format anyway.
     */
-   if (brw->gen >= 9 && srgb_enabled && mt->num_samples <= 1 &&
+   if (brw->gen == 9 && srgb_enabled && mt->num_samples <= 1 &&
        _mesa_get_srgb_format_linear(mt->format) != mt->format) {
 
       /* Lossless compression is not supported for SRGB formats, it