mirror of
https://github.com/skyline-emu/skyline.git
synced 2024-11-26 05:44:18 +01:00
Return a dummy buffer when encountering unbound SSBOs
This commit is contained in:
parent
d893777262
commit
8d9b0041b4
@ -51,6 +51,8 @@ namespace skyline::gpu::interconnect {
|
|||||||
|
|
||||||
size_t padding{ssbo.address & (ctx.gpu.traits.minimumStorageBufferAlignment - 1)};
|
size_t padding{ssbo.address & (ctx.gpu.traits.minimumStorageBufferAlignment - 1)};
|
||||||
cachedView.Update(ctx, ssbo.address - padding, util::AlignUp(ssbo.size + padding, ctx.gpu.traits.minimumStorageBufferAlignment));
|
cachedView.Update(ctx, ssbo.address - padding, util::AlignUp(ssbo.size + padding, ctx.gpu.traits.minimumStorageBufferAlignment));
|
||||||
|
if (!cachedView.view) // Return a dummy buffer if the SSBO isn't bound
|
||||||
|
return BufferBinding{ctx.gpu.megaBufferAllocator.Allocate(ctx.executor.cycle, PAGE_SIZE).buffer, 0, PAGE_SIZE};
|
||||||
|
|
||||||
auto view{cachedView.view};
|
auto view{cachedView.view};
|
||||||
ctx.executor.AttachBuffer(view);
|
ctx.executor.AttachBuffer(view);
|
||||||
|
Loading…
Reference in New Issue
Block a user