Quality slider overwrites custom shader settings. All effects now listen to the new...
[fg:toms-fgdata.git] / Effects / skydome.eff
1 <?xml version="1.0" encoding="utf-8"?>
2 <PropertyList>
3         <name>Effects/skydome</name>
4         <parameters>
5                 <mie>
6                         <use>/sim/rendering/mie</use>
7                 </mie>
8                 <rayleigh>
9                         <use>/sim/rendering/rayleigh</use>
10                 </rayleigh>
11                 <density>
12                         <use>/sim/rendering/dome-density</use>
13                 </density>
14                 <overcast>
15                         <use>/rendering/scene/overcast</use>
16                 </overcast>
17                 <saturation>
18                         <use>/rendering/scene/saturation</use>
19                 </saturation>
20                 <scattering>
21                         <use>/rendering/scene/scattering</use>
22                 </scattering>
23                 <visibility>
24                         <use>/environment/ground-visibility-m</use>
25                 </visibility>
26                 <avisibility>
27                         <use>/environment/visibility-m</use>
28                 </avisibility>
29                 <lthickness>
30                         <use>/environment/ground-haze-thickness-m</use>
31                 </lthickness>
32                 <terminator>
33                         <use>/environment/terminator-relative-position-m</use>
34                 </terminator>
35         </parameters>
36         <technique n="8">
37                 <predicate>
38                         <and>
39                                 <property>/sim/rendering/shaders/skydome</property>
40                                 <or>
41                                         <less-equal>
42                                                 <value type="float">2.0</value>
43                                                 <glversion/>
44                                         </less-equal>
45                                         <and>
46                                                 <extension-supported>GL_ARB_shader_objects</extension-supported>
47                                                 <extension-supported>GL_ARB_shading_language_100</extension-supported>
48                                                 <extension-supported>GL_ARB_vertex_shader</extension-supported>
49                                                 <extension-supported>GL_ARB_fragment_shader</extension-supported>
50                                         </and>
51                                 </or>
52                         </and>
53                 </predicate>
54
55                 <pass>
56                         <lighting>true</lighting>
57                         <shade-model>smooth</shade-model>
58                         <cull-face>back</cull-face>
59                         <program>
60                                 <vertex-shader>Shaders/skydome.vert</vertex-shader>
61                                 <fragment-shader>Shaders/skydome.frag</fragment-shader>
62                         </program>
63                         <uniform>
64                                 <name>mK</name>
65                                 <type>float</type>
66                                 <value>
67                                         <use>mie</use>
68                                 </value>
69                         </uniform>
70                         <uniform>
71                                 <name>rK</name>
72                                 <type>float</type>
73                                 <value>
74                                         <use>rayleigh</use>
75                                 </value>
76                         </uniform>
77                         <uniform>
78                                 <name>density</name>
79                                 <type>float</type>
80                                 <value>
81                                         <use>density</use>
82                                 </value>
83                         </uniform>
84                         <uniform>
85                                 <name>overcast</name>
86                                 <type>float</type>
87                                 <value>
88                                         <use>overcast</use>
89                                 </value>
90                         </uniform>
91                         <uniform>
92                                 <name>saturation</name>
93                                 <type>float</type>
94                                 <value>
95                                         <use>saturation</use>
96                                 </value>
97                         </uniform>
98                         <uniform>
99                                 <name>scattering</name>
100                                 <type>float</type>
101                                 <value>
102                                         <use>scattering</use>
103                                 </value>
104                         </uniform>
105                         <uniform>
106                                 <name>visibility</name>
107                                 <type>float</type>
108                                 <value>
109                                         <use>visibility</use>
110                                 </value>
111                         </uniform>
112                         <uniform>
113                                 <name>hazeLayerAltitude</name>
114                                 <type>float</type>
115                                 <value>
116                                         <use>lthickness</use>
117                                 </value>
118                         </uniform>
119                         <uniform>
120                                 <name>terminator</name>
121                                 <type>float</type>
122                                 <value>
123                                         <use>terminator</use>
124                                 </value>
125                         </uniform>
126                         <uniform>
127                                 <name>avisibility</name>
128                                 <type>float</type>
129                                 <value>
130                                         <use>avisibility</use>
131                                 </value>
132                         </uniform>
133                 </pass>
134         </technique>
135
136         <!-- fall back without shaders -->
137         <technique n="11">
138                 <pass>
139                         <lighting>false</lighting>
140                         <shade-model>smooth</shade-model>
141                         <cull-face>back</cull-face>
142                 </pass>
143         </technique>
144
145 </PropertyList>