mirror of
https://github.com/KhronosGroup/glslang
synced 2024-11-09 12:00:05 +00:00
c1e61d6cff
control shaders. Fix bug in member remapping.
20 lines
535 B
GLSL
20 lines
535 B
GLSL
#version 450
|
|
|
|
#extension GL_NV_viewport_array2 :require
|
|
#extension GL_NV_stereo_view_rendering : require
|
|
|
|
layout(vertices = 4) out;
|
|
|
|
out gl_PerVertex {
|
|
int gl_SecondaryViewportMaskNV[2];
|
|
vec4 gl_SecondaryPositionNV;
|
|
} gl_out[4];
|
|
|
|
layout (viewport_relative, secondary_view_offset = 1) out highp int gl_Layer;
|
|
|
|
void main()
|
|
{
|
|
gl_out[gl_InvocationID].gl_SecondaryViewportMaskNV[0] = 1;
|
|
gl_out[gl_InvocationID].gl_SecondaryPositionNV = gl_in[1].gl_Position + gl_in[1].gl_SecondaryPositionNV;
|
|
}
|