source: GTP/branches/IllumWPdeliver2008dec/IlluminationWP/demos/Standalone/Hierarchical Systems Demo [OpenGL]/src/Angle.cg @ 3255

Revision 3255, 566 bytes checked in by szirmay, 15 years ago (diff)
Line 
1struct VertexOut
2{
3        float4 VertexPosition           :POSITION;
4        float2 TexCoord                         :TEXCOORD;
5};
6
7
8/*
9  Vertex program for cloud rendering
10*/
11VertexOut VertexProgram( float4 Position :POSITION,
12                                                float2 Texcoord: TEXCOORD
13                                                )                                                                       
14{
15        VertexOut Out; 
16       
17        Out.VertexPosition=Position;
18        Out.TexCoord=Texcoord;
19       
20        return Out;     
21}
22
23/*
24  Fragment program for cloud rendering
25*/
26float4 FragmentProgram( VertexOut       In):COLOR
27{
28        float4 Color;
29        float angle=In.TexCoord.y/length(In.TexCoord);
30        Color=float4(angle,1,1,1);
31       
32        return Color;
33}
34
Note: See TracBrowser for help on using the repository browser.