graphics: synchronize raw storage reads with GPU image aliases

This commit is contained in:
Claxten authored and nmzik committed 2026-10-07 21:17:35 +04:00
1 parent 9f83fd5f0c
commit 743fdc6990
2 files changed
+12 -12

No files matched your search

@@ -126,8 +126,8 @@ NativeStorageBuffer(RenderContext& context, const PreparedBindings::BufferSource
if (size > graphics.GetPhysicalDeviceProperties().limits.maxStorageBufferRange) {
EXIT("storage buffer range is unsupported\n");
}
auto [buffer, offset] = context.GetBufferCache().ObtainBuffer(address, size, resource.written,
resource.formatted, id);
auto [buffer, offset] = context.GetBufferCache().ObtainBuffer(
address, size, resource.written, resource.read || resource.formatted, id);
const auto aligned_offset = Common::AlignDown(offset, alignment);
const auto adjustment = offset - aligned_offset;
const auto max_range = graphics.GetPhysicalDeviceProperties().limits.maxStorageBufferRange;