gallivm: disable accurate cube corner for integer textures.
authorDave Airlie <airlied@redhat.com>
Thu, 29 Aug 2019 19:50:26 +0000 (05:50 +1000)
committerDave Airlie <airlied@redhat.com>
Thu, 29 Aug 2019 22:27:16 +0000 (08:27 +1000)
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=111511
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c

index adb6adf143a98dce798789d4765ad3e0760df2d9..48d98bb617a227d063255b2b44bb29ae0ed1caea 100644 (file)
@@ -1037,7 +1037,12 @@ lp_build_sample_image_linear(struct lp_build_sample_context *bld,
                            bld->static_texture_state->target == PIPE_TEXTURE_CUBE_ARRAY) &&
                           bld->static_sampler_state->seamless_cube_map;
 
-   accurate_cube_corners = ACCURATE_CUBE_CORNERS && seamless_cube_filter;
+   /*
+    * Disable accurate cube corners for integer textures, which should only
+    * get here in the gather path.
+    */
+   accurate_cube_corners = ACCURATE_CUBE_CORNERS && seamless_cube_filter &&
+     !util_format_is_pure_integer(bld->static_texture_state->format);
 
    lp_build_extract_image_sizes(bld,
                                 &bld->int_size_bld,