2017-08-23 18:34:42 +00:00
|
|
|
struct S {
|
2017-08-28 20:02:19 +00:00
|
|
|
float4 pos : SV_Position;
|
|
|
|
float2 clip : SV_ClipDistance0;
|
2017-08-23 18:34:42 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
[maxvertexcount(3)]
|
|
|
|
void main(triangle in float4 pos[3] : SV_Position,
|
|
|
|
triangle in uint VertexID[3] : VertexID,
|
|
|
|
inout LineStream<S> OutputStream,
|
2017-08-28 20:02:19 +00:00
|
|
|
triangle in float4 clip[3] : SV_ClipDistance) // externally: an array 3 of array 4 (not vec4!) of float.
|
2017-08-23 18:34:42 +00:00
|
|
|
{
|
|
|
|
S s;
|
|
|
|
|
|
|
|
s.pos = pos[0];
|
2017-08-28 20:02:19 +00:00
|
|
|
s.clip = clip[0].xy;
|
2017-08-23 18:34:42 +00:00
|
|
|
|
|
|
|
OutputStream.Append(s);
|
|
|
|
}
|
|
|
|
|