i965: Enable CCS_E sampling of sRGB textures as UNORM
authorJason Ekstrand <jason.ekstrand@intel.com>
Sat, 9 Dec 2017 06:21:09 +0000 (22:21 -0800)
committerJason Ekstrand <jason.ekstrand@intel.com>
Wed, 17 Jan 2018 05:41:32 +0000 (21:41 -0800)
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/intel_mipmap_tree.c

index c61042e14be1413f9ea3dba9a1782cc83bee5663..b56a51e6f67c8fcb55241c6fc59319911dcd3fd6 100644 (file)
@@ -2570,9 +2570,8 @@ can_texture_with_ccs(struct brw_context *brw,
    if (mt->aux_usage != ISL_AUX_USAGE_CCS_E)
       return false;
 
-   /* TODO: Replace with format_ccs_e_compat_with_miptree for better perf. */
-   if (!isl_formats_are_ccs_e_compatible(&brw->screen->devinfo,
-                                         mt->surf.format, view_format)) {
+   if (!format_ccs_e_compat_with_miptree(&brw->screen->devinfo,
+                                         mt, view_format)) {
       perf_debug("Incompatible sampling format (%s) for rbc (%s)\n",
                  isl_format_get_layout(view_format)->name,
                  _mesa_get_format_name(mt->format));