[vulkan] adjusting BindVertexBuffer2EXT wrong calling in pipeline
This commit is contained in:
parent
2999e0bbc7
commit
dd8aeabb64
|
|
@ -598,7 +598,10 @@ void BufferCacheRuntime::BindVertexBuffer(u32 index, VkBuffer buffer, u32 offset
|
|||
if (index >= device.GetMaxVertexInputBindings()) {
|
||||
return;
|
||||
}
|
||||
if (device.IsExtExtendedDynamicStateSupported()) {
|
||||
const bool use_dynamic_vertex_input_binding_stride =
|
||||
device.IsExtExtendedDynamicStateSupported() &&
|
||||
use_vertex_input_binding_stride_dynamic_state;
|
||||
if (use_dynamic_vertex_input_binding_stride) {
|
||||
scheduler.Record([index, buffer, offset, size, stride](vk::CommandBuffer cmdbuf) {
|
||||
const VkDeviceSize vk_offset = buffer != VK_NULL_HANDLE ? offset : 0;
|
||||
const VkDeviceSize vk_size = buffer != VK_NULL_HANDLE ? size : VK_WHOLE_SIZE;
|
||||
|
|
@ -638,7 +641,10 @@ void BufferCacheRuntime::BindVertexBuffers(VideoCommon::HostBindings<Buffer>& bi
|
|||
if (binding_count == 0) {
|
||||
return;
|
||||
}
|
||||
if (device.IsExtExtendedDynamicStateSupported()) {
|
||||
const bool use_dynamic_vertex_input_binding_stride =
|
||||
device.IsExtExtendedDynamicStateSupported() &&
|
||||
use_vertex_input_binding_stride_dynamic_state;
|
||||
if (use_dynamic_vertex_input_binding_stride) {
|
||||
scheduler.Record([bindings_ = std::move(bindings),
|
||||
buffer_handles_ = std::move(buffer_handles),
|
||||
binding_count](vk::CommandBuffer cmdbuf) {
|
||||
|
|
|
|||
|
|
@ -127,6 +127,10 @@ public:
|
|||
|
||||
void BindVertexBuffers(VideoCommon::HostBindings<Buffer>& bindings);
|
||||
|
||||
void SetUseVertexInputBindingStrideDynamicState(bool enabled) {
|
||||
use_vertex_input_binding_stride_dynamic_state = enabled;
|
||||
}
|
||||
|
||||
void BindTransformFeedbackBuffer(u32 index, VkBuffer buffer, u32 offset, u32 size);
|
||||
|
||||
void BindTransformFeedbackBuffers(VideoCommon::HostBindings<Buffer>& bindings);
|
||||
|
|
@ -183,6 +187,8 @@ private:
|
|||
std::unique_ptr<Uint8Pass> uint8_pass;
|
||||
QuadIndexedPass quad_index_pass;
|
||||
|
||||
bool use_vertex_input_binding_stride_dynamic_state = true;
|
||||
|
||||
bool limit_dynamic_storage_buffers = false;
|
||||
u32 max_dynamic_storage_buffers = (std::numeric_limits<u32>::max)();
|
||||
};
|
||||
|
|
|
|||
|
|
@ -461,6 +461,7 @@ bool GraphicsPipeline::ConfigureImpl(bool is_indexed) {
|
|||
bind_stage_info(4);
|
||||
}
|
||||
|
||||
buffer_cache.runtime.SetUseVertexInputBindingStrideDynamicState(UsesExtendedDynamicState());
|
||||
buffer_cache.UpdateGraphicsBuffers(is_indexed);
|
||||
buffer_cache.BindHostGeometryBuffers(is_indexed);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue