mirror of
https://github.com/RPCS3/glslang.git
synced 2024-12-05 01:37:07 +00:00
39374dadb5
git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@31212 e7fa87d3-cd2b-0410-9028-fcbf551c1848
40 lines
780 B
GLSL
40 lines
780 B
GLSL
#version 150 core
|
|
|
|
layout(triangles_adjacency) in;
|
|
layout(max_vertices = 30) out;
|
|
layout(stream = 3, triangle_strip) out;
|
|
|
|
in fromVertex {
|
|
in vec3 color;
|
|
} fromV[];
|
|
|
|
out toFragment {
|
|
out vec3 color;
|
|
} toF;
|
|
|
|
out fromVertex {
|
|
vec3 color;
|
|
};
|
|
|
|
void main()
|
|
{
|
|
color = fromV[0].color;
|
|
//?? gl_ClipDistance[3] = gl_in[1].gl_ClipDistance[2];
|
|
gl_Position = gl_in[0].gl_Position;
|
|
gl_PointSize = gl_in[3].gl_PointSize;
|
|
gl_PrimitiveID = gl_PrimitiveIDIn;
|
|
gl_Layer = 2;
|
|
|
|
EmitVertex();
|
|
|
|
color = 2 * fromV[0].color;
|
|
gl_Position = 2.0 * gl_in[0].gl_Position;
|
|
gl_PointSize = 2.0 * gl_in[3].gl_PointSize;
|
|
gl_PrimitiveID = gl_PrimitiveIDIn + 1;
|
|
gl_Layer = 3;
|
|
|
|
EmitVertex();
|
|
|
|
EndPrimitive();
|
|
}
|