Browse Source

Add more checks

pull/2832/head
MaranBr 4 months ago
committed by crueter
parent
commit
55fe999f21
  1. 8
      src/video_core/buffer_cache/buffer_cache.h

8
src/video_core/buffer_cache/buffer_cache.h

@ -813,14 +813,18 @@ void BufferCache<P>::BindHostGraphicsUniformBuffer(size_t stage, u32 index, u32
runtime.BindFastUniformBuffer(stage, binding_index, size);
}
const auto span = ImmediateBufferWithData(device_addr, size);
runtime.PushFastUniformBuffer(stage, binding_index, span);
if (!span.empty()) {
runtime.PushFastUniformBuffer(stage, binding_index, span);
}
return;
}
}
channel_state->fast_bound_uniform_buffers[stage] |= 1u << binding_index;
channel_state->uniform_buffer_binding_sizes[stage][binding_index] = size;
const std::span<u8> span = runtime.BindMappedUniformBuffer(stage, binding_index, size);
device_memory.ReadBlockUnsafe(device_addr, span.data(), size);
if (!span.empty()) {
device_memory.ReadBlockUnsafe(device_addr, span.data(), size);
}
return;
}
// Classic cached path

Loading…
Cancel
Save