GPU: State: Add GPU_BARRIER_UNIFORM

This allows to synchronise uniform buffer writes from compute shader
when an UBO is bound as SSBO.
This commit is contained in:
2022-11-15 14:25:04 +01:00
parent f0ce95b7b9
commit 5db84d0ef1
3 changed files with 6 additions and 2 deletions

View File

@@ -31,9 +31,10 @@ typedef enum eGPUBarrier {
GPU_BARRIER_TEXTURE_UPDATE = (1 << 5),
GPU_BARRIER_VERTEX_ATTRIB_ARRAY = (1 << 6),
GPU_BARRIER_ELEMENT_ARRAY = (1 << 7),
GPU_BARRIER_UNIFORM = (1 << 8),
} eGPUBarrier;
ENUM_OPERATORS(eGPUBarrier, GPU_BARRIER_ELEMENT_ARRAY)
ENUM_OPERATORS(eGPUBarrier, GPU_BARRIER_UNIFORM)
/* NOTE: For Metal and Vulkan only.
* TODO(Metal): Update barrier calls to use stage flags. */