0001: //
0002: // Almost fixed function
0003: //
0004: 
0005: // ----------------------------------------------------------------------------
0006: // Input datas
0007: // ----------------------------------------------------------------------------
0008: struct appdata  {
0009:     float4 position  : POSITION;
0010:     float4 texcoord0 : TEXCOORD0;
0011: };
0012: // ----------------------------------------------------------------------------
0013: // Vertex shader program
0014: // ----------------------------------------------------------------------------
0015: vf20 main(appdata I
0016:         , uniform float4x4 worldviewproj_matrix
0017: ) {
0018:     vf20 O;
0019:     
0020:     // Traditional coordinate transformation
0021:     O.HPOS = mul(worldviewproj_matrix, I.position);
0022: 
0023:     // texture coordinates is simply copy the input
0024:     O.TEX0 = I.texcoord0;
0025:     O.TEX1 = I.texcoord0;
0026: 
0027:     return O;
0028: } 
0029: 
0030: 
0031: