SPIRV-Cross/reference/shaders-hlsl/vert/matrix-output.vert
Hans-Kristian Arntzen eb58f67727 Only unroll matrices for vertex input.
Bandaid, might have to revisit this later.
2017-10-05 16:31:52 +02:00

24 lines
540 B
GLSL

static float4 gl_Position;
static float4x4 m;
struct SPIRV_Cross_Output
{
float4x4 m : TEXCOORD0;
float4 gl_Position : SV_Position;
};
void vert_main()
{
gl_Position = float4(1.0f, 1.0f, 1.0f, 1.0f);
m = float4x4(float4(1.0f, 0.0f, 0.0f, 0.0f), float4(0.0f, 1.0f, 0.0f, 0.0f), float4(0.0f, 0.0f, 1.0f, 0.0f), float4(0.0f, 0.0f, 0.0f, 1.0f));
}
SPIRV_Cross_Output main()
{
vert_main();
SPIRV_Cross_Output stage_output;
stage_output.gl_Position = gl_Position;
stage_output.m = m;
return stage_output;
}