https://github.com/shader-slang/slang
Raw File
Tip revision: 926009a58315845b3a3a95e2724486a6c9e987ea authored by Tomáš Pazdiora on 10 May 2024, 01:17:38 UTC
fix typo (#4144)
Tip revision: 926009a
basic-fragment.slang
//TEST:SIMPLE(filecheck=CHECK): -target spirv -stage fragment -entry main -allow-glsl
#version 310 es
precision highp float;
precision highp int;

bool isOk (uint a, uint b)   { return (a == b); }
layout(location = 0) out mediump vec4 dEQP_FragColor;
layout(location = 0) flat in float in0;
layout(binding = 0, std140) uniform Reference
{
	uint out0;
} ref;
uint out0;

void main()
{
	out0 = uint(in0);
	bool RES = isOk(out0, ref.out0);
    dEQP_FragColor = vec4(RES, RES, RES, 1.0);
    // CHECK: OpEntryPoint
}

back to top