mirror of
https://github.com/KhronosGroup/glslang
synced 2024-11-08 19:40:06 +00:00
79a35ace7c
float16_t does not take GLSL precisions and SPIR-V does not support RelaxedPrecision on float16_t. Fixes #2894
17 lines
395 B
GLSL
17 lines
395 B
GLSL
#version 450
|
|
#extension GL_KHR_shader_subgroup_vote: enable
|
|
#extension GL_EXT_shader_subgroup_extended_types_float16 : enable
|
|
layout(set = 0, binding = 0, std430) buffer Buffer1
|
|
{
|
|
uint result[];
|
|
};
|
|
|
|
void main (void)
|
|
{
|
|
uint tempRes;
|
|
float16_t valueNoEqual = float16_t(gl_SubgroupInvocationID);
|
|
tempRes = subgroupAllEqual(valueNoEqual) ? 0x0 : 0x10;
|
|
result[gl_VertexIndex] = tempRes;
|
|
}
|
|
|