mirror of
https://gitea.wildfiregames.com/0ad/0ad
synced 2026-08-15 14:43:32 -07:00
Fixes possible artifacts with GPU skinning on GL
std140 requires 16 bytes alignment and it makes alignment of uvec2 in SkinData be equal to 16 bytes instead of 8 bytes.
This commit is contained in:
parent
15b9a39b00
commit
b3165505b6
1 changed files with 3 additions and 3 deletions
|
|
@ -12,10 +12,10 @@
|
|||
layout(set = 2, binding = LOCATION, FORMAT) uniform image2D NAME
|
||||
#if USE_DESCRIPTOR_INDEXING
|
||||
#define STORAGE_BUFFER(LOCATION) \
|
||||
layout(set = 2, binding = LOCATION)
|
||||
layout(std430, set = 2, binding = LOCATION)
|
||||
#else
|
||||
#define STORAGE_BUFFER(LOCATION) \
|
||||
layout(set = 1, binding = LOCATION)
|
||||
layout(std430, set = 1, binding = LOCATION)
|
||||
#endif
|
||||
#else
|
||||
// We use offset to the binding slot for OpenGL to avoid overlapping with other
|
||||
|
|
@ -23,7 +23,7 @@
|
|||
#define STORAGE_2D(LOCATION, FORMAT, NAME) \
|
||||
layout(binding = LOCATION, FORMAT) uniform image2D NAME
|
||||
#define STORAGE_BUFFER(LOCATION) \
|
||||
layout(binding = LOCATION)
|
||||
layout(std430, binding = LOCATION)
|
||||
#endif
|
||||
|
||||
#endif // STAGE_COMPUTE
|
||||
|
|
|
|||
Loading…
Reference in a new issue