File tree Expand file tree Collapse file tree 2 files changed +46
-0
lines changed Expand file tree Collapse file tree 2 files changed +46
-0
lines changed Original file line number Diff line number Diff line change 1+ #include "common.h"
2+ #include "iostructs\v_editor.h"
3+
4+ uniform float4 tfactor;
5+ v2p _main (vf i)
6+ {
7+ v2p o;
8+
9+ o.P = mul (m_WVP, i.P); // xform, input in world coords
10+ o.C = tfactor* i.C;
11+
12+ return o;
13+ }
Original file line number Diff line number Diff line change 1+
2+ out gl_PerVertex { vec4 gl_Position ; };
3+
4+ struct vf
5+ {
6+ float4 C ; // COLOR0;
7+ float4 P ; // POSITION;
8+ };
9+
10+ struct v2p
11+ {
12+ float4 C ; // COLOR0;
13+ float4 P ; // SV_Position;
14+ };
15+
16+ layout (location = COLOR0 ) in float4 v_editor_C ; // COLOR0;
17+ layout (location = POSITION ) in float4 v_editor_P ; // POSITION;
18+
19+ layout (location = COLOR0 ) out float4 v2p_editor_C ; // COLOR0;
20+
21+ v2p _main (vf i );
22+
23+ void main ()
24+ {
25+ vf I ;
26+ I .C = v_editor_C ;
27+ I .P = v_editor_P ;
28+
29+ v2p O = _main (I );
30+
31+ v2p_editor_C = O .C ;
32+ gl_Position = O .P ;
33+ }
You can’t perform that action at this time.
0 commit comments