Mesa (main): anv: VK_EXT_border_color_swizzle

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Jun 14 02:21:44 UTC 2022


Module: Mesa
Branch: main
Commit: fbcf65bfea52a03ab8c78eabcfd1c7193334c088
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=fbcf65bfea52a03ab8c78eabcfd1c7193334c088

Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date:   Sat Jun 11 14:10:33 2022 -0400

anv: VK_EXT_border_color_swizzle

Reviewed-by: Jason Ekstrand <jason.ekstrand at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16992>

---

 docs/features.txt              | 2 +-
 docs/relnotes/new_features.txt | 2 +-
 src/intel/vulkan/anv_device.c  | 8 ++++++++
 3 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/docs/features.txt b/docs/features.txt
index 2603841da4b..d750cf8a16b 100644
--- a/docs/features.txt
+++ b/docs/features.txt
@@ -529,7 +529,7 @@ Khronos extensions that are not part of any Vulkan version:
   VK_KHR_win32_surface                                  DONE (lvp)
   VK_KHR_xcb_surface                                    DONE (anv, lvp, radv, tu, v3dv, vn)
   VK_KHR_xlib_surface                                   DONE (anv, lvp, radv, tu, v3dv, vn)
-  VK_EXT_border_color_swizzle                           DONE (lvp)
+  VK_EXT_border_color_swizzle                           DONE (anv, lvp)
   VK_EXT_buffer_device_address                          DONE (radv)
   VK_EXT_calibrated_timestamps                          DONE (anv, lvp, radv)
   VK_EXT_color_write_enable                             DONE (anv, lvp, radv, v3dv)
diff --git a/docs/relnotes/new_features.txt b/docs/relnotes/new_features.txt
index 3b25755f117..5dd587b538c 100644
--- a/docs/relnotes/new_features.txt
+++ b/docs/relnotes/new_features.txt
@@ -7,4 +7,4 @@ vertexAttributeInstanceRateZeroDivisor support for lavapipe
 panfrost Valhall support (conformant OpenGL ES 3.1 on Mali-G57)
 VK_EXT_primitives_generated_query on RADV
 VK_EXT_non_seamless_cube_map on RADV, ANV
-VK_EXT_border_color_swizzle on lavapipe
+VK_EXT_border_color_swizzle on lavapipe, ANV
diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c
index aedd385e424..ec0ff836687 100644
--- a/src/intel/vulkan/anv_device.c
+++ b/src/intel/vulkan/anv_device.c
@@ -254,6 +254,7 @@ get_device_extensions(const struct anv_physical_device *device,
       .KHR_workgroup_memory_explicit_layout  = true,
       .KHR_zero_initialize_workgroup_memory  = true,
       .EXT_4444_formats                      = true,
+      .EXT_border_color_swizzle              = true,
       .EXT_buffer_device_address             = device->has_a64_buffer_access,
       .EXT_calibrated_timestamps             = device->has_reg_timestamp,
       .EXT_color_write_enable                = true,
@@ -1512,6 +1513,13 @@ void anv_GetPhysicalDeviceFeatures2(
          break;
       }
 
+      case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_BORDER_COLOR_SWIZZLE_FEATURES_EXT: {
+         VkPhysicalDeviceBorderColorSwizzleFeaturesEXT *features =
+            (VkPhysicalDeviceBorderColorSwizzleFeaturesEXT *)ext;
+         features->borderColorSwizzle = true;
+         features->borderColorSwizzleFromImage = true;
+         break;
+      }
 
       case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COLOR_WRITE_ENABLE_FEATURES_EXT: {
          VkPhysicalDeviceColorWriteEnableFeaturesEXT *features =



More information about the mesa-commit mailing list