Mesa (master): i965/fs_surface_builder: Explicitly handle FORMAT_NONE in num_image_coordinates
Jason Ekstrand
jekstrand at kemper.freedesktop.org
Fri Apr 22 03:45:38 UTC 2016
Module: Mesa
Branch: master
Commit: 24bb75049ba0f5cdda5808fcdbb659f2dd3ce45b
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=24bb75049ba0f5cdda5808fcdbb659f2dd3ce45b
Author: Jason Ekstrand <jason.ekstrand at intel.com>
Date: Wed Nov 4 15:12:19 2015 -0800
i965/fs_surface_builder: Explicitly handle FORMAT_NONE in num_image_coordinates
Previously, we were relying on has_matching_typed_format returning true for
MESA_FORMAT_NONE which, in turn, relied on _mesa_get_format_bytes returning
1 for MESA_FORMAT_NONE. When we switch to ISL, this behaviour will no
longer be something we can rely on.
Reviewed-by: Chad Versace <chad.versace at intel.com>
---
src/mesa/drivers/dri/i965/brw_fs_surface_builder.cpp | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_surface_builder.cpp b/src/mesa/drivers/dri/i965/brw_fs_surface_builder.cpp
index 04d1cd2..0932336 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_surface_builder.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_surface_builder.cpp
@@ -410,6 +410,7 @@ namespace {
* reads want the array index to be at the Z component.
*/
const bool array_index_at_z =
+ format != MESA_FORMAT_NONE &&
!image_format_info::has_matching_typed_format(
bld.shader->devinfo, format);
const unsigned zero_dims =
More information about the mesa-commit
mailing list