diff options
| author | Mai <mai.iam2048@gmail.com> | 2023-12-21 10:35:48 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-12-21 10:35:48 -0500 |
| commit | f7b655e5da3edfa7a83c510f92c364b8f4c174e5 (patch) | |
| tree | 3bfa26c32725b5116ecaa32cd0218ed0e10b73c0 /Source/Core/VideoBackends/Vulkan/ObjectCache.cpp | |
| parent | 70b7a59456164606833ebe45e7d790b8f03aab7a (diff) | |
| parent | 79648e1c24eac81f54365bbcb6dbc49ad6b16b1c (diff) | |
Merge pull request #12456 from iwubcode/android_reduce_pixel_samplers_to_8
VideoCommon: revert max pixel samplers back to 8 for Android
Diffstat (limited to 'Source/Core/VideoBackends/Vulkan/ObjectCache.cpp')
| -rw-r--r-- | Source/Core/VideoBackends/Vulkan/ObjectCache.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/Core/VideoBackends/Vulkan/ObjectCache.cpp b/Source/Core/VideoBackends/Vulkan/ObjectCache.cpp index c32365f3fc..a27d4457e2 100644 --- a/Source/Core/VideoBackends/Vulkan/ObjectCache.cpp +++ b/Source/Core/VideoBackends/Vulkan/ObjectCache.cpp @@ -121,6 +121,12 @@ bool ObjectCache::CreateDescriptorSetLayouts() VK_SHADER_STAGE_GEOMETRY_BIT}, }}; +#ifdef ANDROID + static const std::array<VkDescriptorSetLayoutBinding, 1> standard_sampler_bindings{{ + {0, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, + static_cast<u32>(VideoCommon::MAX_PIXEL_SHADER_SAMPLERS), VK_SHADER_STAGE_FRAGMENT_BIT}, + }}; +#else constexpr u32 MAX_PIXEL_SAMPLER_ARRAY_SIZE = 8; constexpr u32 TOTAL_PIXEL_SAMPLER_BINDINGS = 1 + (VideoCommon::MAX_PIXEL_SHADER_SAMPLERS - MAX_PIXEL_SAMPLER_ARRAY_SIZE); @@ -139,6 +145,7 @@ bool ObjectCache::CreateDescriptorSetLayouts() {14, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, 1, VK_SHADER_STAGE_FRAGMENT_BIT}, {15, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, 1, VK_SHADER_STAGE_FRAGMENT_BIT}, }}; +#endif // The dynamic veretex loader's vertex buffer must be last here, for similar reasons static const std::array<VkDescriptorSetLayoutBinding, 2> standard_ssbo_bindings{{ |
