Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/FICN/Media/materials/scripts/Examples.program @ 539

Last change on this file since 539 was 337, checked in by bknecht, 17 years ago

merged merger to FICN branch

File size: 4.2 KB
Line 
1//---------------------------------------------------
2// This file includes a number of basic GPU programs
3// for use in many materials.
4//---------------------------------------------------
5
6
7// A really basic ambient pass program, support for one texture coodinate set
8vertex_program Ogre/BasicVertexPrograms/AmbientOneTexture cg
9{
10        source Example_Basic.cg
11        entry_point ambientOneTexture_vp
12        profiles vs_1_1 arbvp1
13
14        default_params
15        {
16                param_named_auto worldViewProj worldviewproj_matrix
17                param_named_auto ambient ambient_light_colour
18        }
19       
20}
21// A really basic ambient pass program, support for one texture coodinate set
22vertex_program Ogre/BasicVertexPrograms/AmbientOneTextureHLSL hlsl
23{
24        source Example_Basic.hlsl
25        entry_point ambientOneTexture_vp
26        target vs_1_1
27
28        default_params
29        {
30                param_named_auto worldViewProj worldviewproj_matrix
31                param_named_auto ambient ambient_light_colour
32        }
33}
34// A really basic ambient pass program, support for one texture coodinate set
35vertex_program Ogre/BasicVertexPrograms/AmbientOneTextureGLSL glsl
36{
37        source AmbientOneTexture.glsl
38
39        default_params
40        {
41                param_named_auto ambient ambient_light_colour
42        }
43}
44
45vertex_program Ogre/BasicVertexPrograms/AmbientOneTextureUnified unified
46{
47        delegate Ogre/BasicVertexPrograms/AmbientOneTextureGLSL
48        delegate Ogre/BasicVertexPrograms/AmbientOneTextureHLSL
49}
50
51
52// Same as below, but for use when rendering texture shadows
53vertex_program Ogre/HardwareSkinningOneWeightShadowCaster cg
54{
55        source Example_Basic.cg
56        entry_point hardwareSkinningOneWeightCaster_vp
57        profiles vs_1_1 arbvp1
58        includes_skeletal_animation true
59}
60// Basic hardware skinning using one indexed weight per vertex
61vertex_program Ogre/HardwareSkinningOneWeight cg
62{
63   source Example_Basic.cg
64   entry_point hardwareSkinningOneWeight_vp
65   profiles vs_1_1 arbvp1
66   includes_skeletal_animation true   
67}
68// Same as below, but for use when rendering texture shadows
69vertex_program Ogre/HardwareSkinningTwoWeightsShadowCasterCg cg
70{
71        source Example_Basic.cg
72        entry_point hardwareSkinningTwoWeightsCaster_vp
73        profiles vs_1_1 arbvp1
74        includes_skeletal_animation true
75}
76
77vertex_program Ogre/HardwareSkinningTwoWeightsShadowCasterGLSL glsl
78{
79        source skinningTwoWeightsShadowCasterVp.glsl
80        includes_skeletal_animation true
81}
82
83vertex_program Ogre/HardwareSkinningTwoWeightsShadowCaster unified
84{
85        delegate Ogre/HardwareSkinningTwoWeightsShadowCasterGLSL
86        delegate Ogre/HardwareSkinningTwoWeightsShadowCasterCg
87}
88
89// Basic hardware skinning using two indexed weights per vertex
90vertex_program Ogre/HardwareSkinningTwoWeightsCg cg
91{
92   source Example_Basic.cg
93   entry_point hardwareSkinningTwoWeights_vp
94   profiles vs_1_1 arbvp1
95   includes_skeletal_animation true
96}
97
98vertex_program Ogre/HardwareSkinningTwoWeightsGLSL glsl
99{
100   source skinningTwoWeightsVp.glsl
101   includes_skeletal_animation true
102}
103
104vertex_program Ogre/HardwareSkinningTwoWeights unified
105{
106        delegate Ogre/HardwareSkinningTwoWeightsGLSL
107        delegate Ogre/HardwareSkinningTwoWeightsCg
108       
109   default_params
110   {
111                param_named_auto worldMatrix3x4Array world_matrix_array_3x4
112                param_named_auto viewProjectionMatrix viewproj_matrix
113                param_named_auto lightPos[0] light_position 0
114                param_named_auto lightPos[1] light_position 1
115                param_named_auto lightDiffuseColour[0] light_diffuse_colour 0
116                param_named_auto lightDiffuseColour[1] light_diffuse_colour 1
117   }
118}
119
120// Basic hardware skinning using four indexed weights per vertex
121vertex_program Ogre/HardwareSkinningFourWeights cg
122{
123   source Example_Basic.cg
124   entry_point hardwareSkinningFourWeights_vp
125   profiles vs_1_1 arbvp1
126   includes_skeletal_animation true
127
128}
129// Basic hardware morph animation
130vertex_program Ogre/HardwareMorphAnimation cg
131{
132        source Example_Basic.cg
133        entry_point hardwareMorphAnimation
134        profiles vs_1_1 arbvp1
135
136        includes_morph_animation true
137        default_params
138        {
139                param_named_auto worldViewProj worldviewproj_matrix
140                param_named_auto anim_t animation_parametric
141        }
142}
143// Basic hardware pose animation supporting 2 active poses
144vertex_program Ogre/HardwarePoseAnimation cg
145{
146        source Example_Basic.cg
147        entry_point hardwarePoseAnimation
148        profiles vs_1_1 arbvp1
149
150        includes_pose_animation 2
151        default_params
152        {
153                param_named_auto worldViewProj worldviewproj_matrix
154                param_named_auto anim_t animation_parametric
155        }
156}
157
158
Note: See TracBrowser for help on using the repository browser.