Browse Source

Fix building issues

stuffmadeforfun
CamilleLaVey 1 month ago
parent
commit
96422c0896
  1. 4
      src/video_core/renderer_vulkan/vk_texture_cache.cpp
  2. 10
      src/video_core/vulkan_common/vulkan_device.h

4
src/video_core/renderer_vulkan/vk_texture_cache.cpp

@ -2362,8 +2362,8 @@ Sampler::Sampler(TextureCacheRuntime& runtime, const Tegra::Texture::TSCEntry& t
// 2. If only customBorderColors: Use VK_BORDER_COLOR_FLOAT_CUSTOM_EXT + specific format (spec compliant)
// 3. If only customBorderColorWithoutFormat: Shouldn't happen per spec, but handle as case 2
// 4. If neither: Use standard border colors (fallback)
const bool has_custom_colors = device.features.custom_border_color.customBorderColors;
const bool has_without_format = device.features.custom_border_color.customBorderColorWithoutFormat;
const bool has_custom_colors = device.HasCustomBorderColorFeature();
const bool has_without_format = device.HasCustomBorderColorWithoutFormatFeature();
const bool use_custom_border = arbitrary_borders && has_custom_colors;
const VkSamplerCustomBorderColorCreateInfoEXT border_ci{

10
src/video_core/vulkan_common/vulkan_device.h

@ -552,6 +552,16 @@ public:
return extensions.custom_border_color;
}
/// Returns true if customBorderColors feature is enabled (allows VK_BORDER_COLOR_*_CUSTOM_EXT).
bool HasCustomBorderColorFeature() const {
return features.custom_border_color.customBorderColors;
}
/// Returns true if customBorderColorWithoutFormat feature is enabled (allows VK_FORMAT_UNDEFINED).
bool HasCustomBorderColorWithoutFormatFeature() const {
return features.custom_border_color.customBorderColorWithoutFormat;
}
/// Base Vulkan Dynamic State support checks.
/// These provide granular control over each base dynamic state, allowing individual states
/// to be disabled if broken driver implementations are detected at device initialization.

Loading…
Cancel
Save