SPIRV-Cross/reference/shaders-msl/frag/16bit-constants.invalid.frag
Chip Davis 343c6f4ff4 Update external repos.
Fix fallout from changes.

There's a bug in glslang that prevents `float16_t`, `[u]int16_t`, and
`[u]int8_t` constants from adding the corresponding SPIR-V capabilities.
SPIRV-Tools, meanwhile, tightened validation so that these constants are
only valid if the corresponding `Float16`, `Int16`, and `Int8` caps are
on. This affects the `16bit-constants.frag` test for GLSL and MSL.
2019-07-13 16:50:21 -05:00

22 lines
311 B
GLSL

#include <metal_stdlib>
#include <simd/simd.h>
using namespace metal;
struct main0_out
{
half foo [[color(0)]];
short bar [[color(1)]];
ushort baz [[color(2)]];
};
fragment main0_out main0()
{
main0_out out = {};
out.foo = half(1.0);
out.bar = 2;
out.baz = 3u;
return out;
}