a5d82d1138
Previously, when generating non-Vulkan GLSL, each use of a spec constant would be subsituted for its default value and the declaration of the constant itself would be omitted completely. This change slightly alters this behavior. The uses of the constant are kept, as well as the declaration, although the latter is stripped of the layout qualifier. The declaration is also prepended with the following code: #ifndef <constant name>_value #define <constant name> <default constant value> #endif and the constant itself now looks like const <constant type> <constant name> = <constant name>_value; The rationale for this change is that it gives the user a way to provide custom values for specialization constants even when the target does not support them. |
||
---|---|---|
.. | ||
amd | ||
asm | ||
comp | ||
desktop-only | ||
flatten | ||
frag | ||
geom | ||
legacy | ||
tesc | ||
tese | ||
vert | ||
vulkan |