Browse Source

Revert "fix it goddamn"

eds-true-adreno-fixes
CamilleLaVey 1 month ago
committed by Caio Oliveira
parent
commit
bacd7f5ee1
  1. 8
      src/video_core/vulkan_common/vulkan_device.cpp
  2. 4
      src/video_core/vulkan_common/vulkan_device.h

8
src/video_core/vulkan_common/vulkan_device.cpp

@ -1261,13 +1261,9 @@ bool Device::GetSuitability(bool requires_swapchain) {
SetNext(next, properties.float_controls); SetNext(next, properties.float_controls);
} }
if (extensions.shader_float_controls2) { if (extensions.shader_float_controls2) {
#ifdef VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FLOAT_CONTROLS_PROPERTIES_2_KHR
properties.float_controls2.sType = properties.float_controls2.sType =
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FLOAT_CONTROLS_PROPERTIES_2_KHR; VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FLOAT_CONTROLS_PROPERTIES_2_KHR;
SetNext(next, properties.float_controls2); SetNext(next, properties.float_controls2);
#else
LOG_INFO(Render_Vulkan, "VK_KHR_shader_float_controls2 available but Vulkan headers lack VkPhysicalDeviceFloatControlsProperties2KHR; skipping properties2 chaining");
#endif
} }
if (extensions.push_descriptor) { if (extensions.push_descriptor) {
properties.push_descriptor.sType = properties.push_descriptor.sType =
@ -1301,15 +1297,11 @@ bool Device::GetSuitability(bool requires_swapchain) {
// If VK_KHR_shader_float_controls2 is available, copy its inner properties for // If VK_KHR_shader_float_controls2 is available, copy its inner properties for
// backwards compatibility with code that expects VkPhysicalDeviceFloatControlsProperties. // backwards compatibility with code that expects VkPhysicalDeviceFloatControlsProperties.
if (extensions.shader_float_controls2) { if (extensions.shader_float_controls2) {
#ifdef VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FLOAT_CONTROLS_PROPERTIES_2_KHR
properties.float_controls = properties.float_controls2.floatControls; properties.float_controls = properties.float_controls2.floatControls;
LOG_INFO(Render_Vulkan, LOG_INFO(Render_Vulkan,
"VK_KHR_shader_float_controls2 supported: denormBehaviorIndependence={}, roundingModeIndependence={}", "VK_KHR_shader_float_controls2 supported: denormBehaviorIndependence={}, roundingModeIndependence={}",
properties.float_controls.denormBehaviorIndependence, properties.float_controls.denormBehaviorIndependence,
properties.float_controls.roundingModeIndependence); properties.float_controls.roundingModeIndependence);
#else
LOG_INFO(Render_Vulkan, "VK_KHR_shader_float_controls2 present but float_controls2 struct not available in headers; cannot copy floatControls");
#endif
} }
// Store base properties // Store base properties

4
src/video_core/vulkan_common/vulkan_device.h

@ -345,12 +345,10 @@ public:
return properties.float_controls; return properties.float_controls;
} }
#ifdef VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FLOAT_CONTROLS_PROPERTIES_2_KHR
/// Returns float control properties (KHR v2) of the device. /// Returns float control properties (KHR v2) of the device.
const VkPhysicalDeviceFloatControlsProperties2KHR& FloatControlProperties2() const { const VkPhysicalDeviceFloatControlsProperties2KHR& FloatControlProperties2() const {
return properties.float_controls2; return properties.float_controls2;
} }
#endif
/// Returns true if ASTC is natively supported. /// Returns true if ASTC is natively supported.
@ -1057,9 +1055,7 @@ private:
VkPhysicalDeviceDriverProperties driver{}; VkPhysicalDeviceDriverProperties driver{};
VkPhysicalDeviceSubgroupProperties subgroup_properties{}; VkPhysicalDeviceSubgroupProperties subgroup_properties{};
VkPhysicalDeviceFloatControlsProperties float_controls{}; VkPhysicalDeviceFloatControlsProperties float_controls{};
#ifdef VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FLOAT_CONTROLS_PROPERTIES_2_KHR
VkPhysicalDeviceFloatControlsProperties2KHR float_controls2{}; VkPhysicalDeviceFloatControlsProperties2KHR float_controls2{};
#endif
VkPhysicalDevicePushDescriptorPropertiesKHR push_descriptor{}; VkPhysicalDevicePushDescriptorPropertiesKHR push_descriptor{};
VkPhysicalDeviceSubgroupSizeControlProperties subgroup_size_control{}; VkPhysicalDeviceSubgroupSizeControlProperties subgroup_size_control{};
VkPhysicalDeviceTransformFeedbackPropertiesEXT transform_feedback{}; VkPhysicalDeviceTransformFeedbackPropertiesEXT transform_feedback{};

Loading…
Cancel
Save