mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-05-13 02:18:35 +02:00
[vk] MAX_IMAGE_ELEMENTS 64 -> 128 to prevent crashes
Signed-off-by: lizzie <lizzie@eden-emu.dev>
This commit is contained in:
parent
91058d7383
commit
d55b483801
1 changed files with 3 additions and 5 deletions
|
|
@ -8,7 +8,6 @@
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <span>
|
#include <span>
|
||||||
|
|
||||||
#include <boost/container/small_vector.hpp>
|
|
||||||
#include <boost/container/static_vector.hpp>
|
#include <boost/container/static_vector.hpp>
|
||||||
#include <fmt/format.h>
|
#include <fmt/format.h>
|
||||||
|
|
||||||
|
|
@ -37,7 +36,6 @@
|
||||||
|
|
||||||
namespace Vulkan {
|
namespace Vulkan {
|
||||||
namespace {
|
namespace {
|
||||||
using boost::container::small_vector;
|
|
||||||
using boost::container::static_vector;
|
using boost::container::static_vector;
|
||||||
using Shader::ImageBufferDescriptor;
|
using Shader::ImageBufferDescriptor;
|
||||||
using Shader::Backend::SPIRV::RENDERAREA_LAYOUT_OFFSET;
|
using Shader::Backend::SPIRV::RENDERAREA_LAYOUT_OFFSET;
|
||||||
|
|
@ -49,7 +47,7 @@ using VideoCore::Surface::PixelFormatFromDepthFormat;
|
||||||
using VideoCore::Surface::PixelFormatFromRenderTargetFormat;
|
using VideoCore::Surface::PixelFormatFromRenderTargetFormat;
|
||||||
|
|
||||||
constexpr size_t NUM_STAGES = Maxwell::MaxShaderStage;
|
constexpr size_t NUM_STAGES = Maxwell::MaxShaderStage;
|
||||||
constexpr size_t INLINE_IMAGE_ELEMENTS = 64;
|
constexpr size_t MAX_IMAGE_ELEMENTS = 128;
|
||||||
|
|
||||||
DescriptorLayoutBuilder MakeBuilder(const Device& device, std::span<const Shader::Info> infos) {
|
DescriptorLayoutBuilder MakeBuilder(const Device& device, std::span<const Shader::Info> infos) {
|
||||||
DescriptorLayoutBuilder builder{device};
|
DescriptorLayoutBuilder builder{device};
|
||||||
|
|
@ -314,8 +312,8 @@ void GraphicsPipeline::AddTransition(GraphicsPipeline* transition) {
|
||||||
|
|
||||||
template <typename Spec>
|
template <typename Spec>
|
||||||
bool GraphicsPipeline::ConfigureImpl(bool is_indexed) {
|
bool GraphicsPipeline::ConfigureImpl(bool is_indexed) {
|
||||||
small_vector<VideoCommon::ImageViewInOut, INLINE_IMAGE_ELEMENTS> views;
|
boost::container::static_vector<VideoCommon::ImageViewInOut, MAX_IMAGE_ELEMENTS> views;
|
||||||
small_vector<VideoCommon::SamplerId, INLINE_IMAGE_ELEMENTS> samplers;
|
boost::container::static_vector<VideoCommon::SamplerId, MAX_IMAGE_ELEMENTS> samplers;
|
||||||
views.reserve(num_image_elements);
|
views.reserve(num_image_elements);
|
||||||
samplers.reserve(num_textures);
|
samplers.reserve(num_textures);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue