mirror of
https://github.com/libretro/RetroArch
synced 2025-02-09 00:40:09 +00:00
2820ab0b51 Merge pull request #1076 from KhronosGroup/bitcast-pre-330-glsl 63bcbd511e GLSL: Need extension to use bitcast on GLSL < 330. 9f3bebe3d0 Merge pull request #1075 from lifpan/master b11c20fc1d Remove unreasonable assertion for OpTypeImage Sampled parameter. 1a592b7c0f Merge pull request #1067 from cdavis5e/msl-scalar-block-layout 28454facbb MSL: Handle packed matrices. ea5c0ed82f MSL: Fix alignment of packed types. 44f688bf0b Merge pull request #1070 from KhronosGroup/fix-1066 25c74b324e Forget loop variable enables after emitting block chain. 6b010e0cbc Merge pull request #1069 from KhronosGroup/fix-1053 f6f849397e MSL: Re-roll array expressions in initializers. e5fa7edfd6 MSL: Support scalar block layout. git-subtree-dir: deps/SPIRV-Cross git-subtree-split: 2820ab0b51bf5e4187435d904b34e762b988f48b
51 lines
1.2 KiB
GLSL
51 lines
1.2 KiB
GLSL
static float4 gl_Position;
|
|
static float vFlat;
|
|
static float vCentroid;
|
|
static float vSample;
|
|
static float vNoperspective;
|
|
|
|
struct Block
|
|
{
|
|
nointerpolation float vFlat : TEXCOORD4;
|
|
centroid float vCentroid : TEXCOORD5;
|
|
sample float vSample : TEXCOORD6;
|
|
noperspective float vNoperspective : TEXCOORD7;
|
|
};
|
|
|
|
static Block vout;
|
|
|
|
struct SPIRV_Cross_Output
|
|
{
|
|
nointerpolation float vFlat : TEXCOORD0;
|
|
centroid float vCentroid : TEXCOORD1;
|
|
sample float vSample : TEXCOORD2;
|
|
noperspective float vNoperspective : TEXCOORD3;
|
|
float4 gl_Position : SV_Position;
|
|
};
|
|
|
|
void vert_main()
|
|
{
|
|
gl_Position = 1.0f.xxxx;
|
|
vFlat = 0.0f;
|
|
vCentroid = 1.0f;
|
|
vSample = 2.0f;
|
|
vNoperspective = 3.0f;
|
|
vout.vFlat = 0.0f;
|
|
vout.vCentroid = 1.0f;
|
|
vout.vSample = 2.0f;
|
|
vout.vNoperspective = 3.0f;
|
|
}
|
|
|
|
SPIRV_Cross_Output main(out Block stage_outputvout)
|
|
{
|
|
vert_main();
|
|
stage_outputvout = vout;
|
|
SPIRV_Cross_Output stage_output;
|
|
stage_output.gl_Position = gl_Position;
|
|
stage_output.vFlat = vFlat;
|
|
stage_output.vCentroid = vCentroid;
|
|
stage_output.vSample = vSample;
|
|
stage_output.vNoperspective = vNoperspective;
|
|
return stage_output;
|
|
}
|