=?UTF-8?Q?J=C3=B3zef=20Kucia=20?=: wined3d: Avoid enabling all features supported by Vulkan physical device.

Alexandre Julliard julliard at winehq.org
Fri Apr 19 17:30:46 CDT 2019


Module: wine
Branch: master
Commit: d2f477dd729ca54f40acee37f96483c26054b2bd
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=d2f477dd729ca54f40acee37f96483c26054b2bd

Author: Józef Kucia <jkucia at codeweavers.com>
Date:   Fri Apr 19 12:50:14 2019 +0200

wined3d: Avoid enabling all features supported by Vulkan physical device.

Signed-off-by: Józef Kucia <jkucia at codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/wined3d/adapter_vk.c | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/dlls/wined3d/adapter_vk.c b/dlls/wined3d/adapter_vk.c
index e573c66..4c01fb8 100644
--- a/dlls/wined3d/adapter_vk.c
+++ b/dlls/wined3d/adapter_vk.c
@@ -165,6 +165,32 @@ static HRESULT wined3d_select_vulkan_queue_family(const struct wined3d_adapter_v
     return E_FAIL;
 }
 
+static void wined3d_disable_vulkan_features(VkPhysicalDeviceFeatures *features)
+{
+    features->depthBounds = VK_FALSE;
+    features->alphaToOne = VK_FALSE;
+    features->textureCompressionETC2 = VK_FALSE;
+    features->textureCompressionASTC_LDR = VK_FALSE;
+    features->shaderStorageImageMultisample = VK_FALSE;
+    features->shaderUniformBufferArrayDynamicIndexing = VK_FALSE;
+    features->shaderSampledImageArrayDynamicIndexing = VK_FALSE;
+    features->shaderStorageBufferArrayDynamicIndexing = VK_FALSE;
+    features->shaderStorageImageArrayDynamicIndexing = VK_FALSE;
+    features->shaderInt16 = VK_FALSE;
+    features->shaderResourceResidency = VK_FALSE;
+    features->shaderResourceMinLod = VK_FALSE;
+    features->sparseBinding = VK_FALSE;
+    features->sparseResidencyBuffer = VK_FALSE;
+    features->sparseResidencyImage2D = VK_FALSE;
+    features->sparseResidencyImage3D = VK_FALSE;
+    features->sparseResidency2Samples = VK_FALSE;
+    features->sparseResidency4Samples = VK_FALSE;
+    features->sparseResidency8Samples = VK_FALSE;
+    features->sparseResidency16Samples = VK_FALSE;
+    features->sparseResidencyAliased = VK_FALSE;
+    features->inheritedQueries = VK_FALSE;
+}
+
 static HRESULT adapter_vk_create_device(struct wined3d *wined3d, const struct wined3d_adapter *adapter,
         enum wined3d_device_type device_type, HWND focus_window, unsigned int flags, BYTE surface_alignment,
         const enum wined3d_feature_level *levels, unsigned int level_count,
@@ -192,6 +218,7 @@ static HRESULT adapter_vk_create_device(struct wined3d *wined3d, const struct wi
     physical_device = adapter_vk->physical_device;
 
     VK_CALL(vkGetPhysicalDeviceFeatures(physical_device, &features));
+    wined3d_disable_vulkan_features(&features);
 
     queue_info.sType = VK_STRUCTURE_TYPE_DEVICE_QUEUE_CREATE_INFO;
     queue_info.pNext = NULL;




More information about the wine-cvs mailing list