Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: data/Media/materials/scripts/Examples.program @ 5134

Last change on this file since 5134 was 5134, checked in by janise, 17 years ago

try to fix it once again

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