Merge branch 'master' of git://gitorious.org/fg/fgdata
This commit is contained in:
commit
bd909173f5
6 changed files with 36 additions and 32 deletions
|
@ -125,7 +125,7 @@
|
|||
<program>
|
||||
<vertex-shader n="0">Shaders/include_fog.vert</vertex-shader>
|
||||
<vertex-shader n="1">Shaders/default.vert</vertex-shader>
|
||||
<vertex-shader n="0">Shaders/include_fog.frag</vertex-shader>
|
||||
<fragment-shader n="0">Shaders/include_fog.frag</fragment-shader>
|
||||
<fragment-shader n="1">Shaders/terrain-nocolor.frag</fragment-shader>
|
||||
</program>
|
||||
<uniform>
|
||||
|
|
|
@ -15,22 +15,22 @@ var Factor = 0.0004;
|
|||
var Sharp = 1.0;
|
||||
|
||||
#add control properies for waves
|
||||
wave_amp_Node = props.globals.getNode("/environment/wave/amp" , 1);
|
||||
var wave_amp_Node = props.globals.getNode("/environment/wave/amp" , 1);
|
||||
wave_amp_Node.setDoubleValue(Amp);
|
||||
|
||||
wave_freq_Node = props.globals.getNode("/environment/wave/freq" , 1);
|
||||
var wave_freq_Node = props.globals.getNode("/environment/wave/freq" , 1);
|
||||
wave_freq_Node.setDoubleValue(Freq);
|
||||
|
||||
wave_sharp_Node = props.globals.getNode("/environment/wave/sharp" , 1);
|
||||
var wave_sharp_Node = props.globals.getNode("/environment/wave/sharp" , 1);
|
||||
wave_sharp_Node.setDoubleValue(Sharp);
|
||||
|
||||
wave_angle_Node = props.globals.getNode("/environment/wave/angle" , 1);
|
||||
var wave_angle_Node = props.globals.getNode("/environment/wave/angle" , 1);
|
||||
wave_angle_Node.setDoubleValue(Angle);
|
||||
|
||||
wave_factor_Node = props.globals.getNode("/environment/wave/factor" , 1);
|
||||
var wave_factor_Node = props.globals.getNode("/environment/wave/factor" , 1);
|
||||
wave_factor_Node.setDoubleValue(Factor);
|
||||
|
||||
wave_factor_Node = props.globals.getNode("/environment/wave/dangle" , 1);
|
||||
var wave_factor_Node = props.globals.getNode("/environment/wave/dangle" , 1);
|
||||
wave_factor_Node.setDoubleValue(DAngle);
|
||||
|
||||
props.globals.initNode("/environment/sea/surface/wind-speed-kt", 0, "DOUBLE");
|
||||
|
@ -46,28 +46,28 @@ props.globals.initNode("/orientation/model/roll-deg", 0, "DOUBLE");
|
|||
|
||||
var initialize = func {
|
||||
|
||||
wind_from_east_Node = props.globals.getNode("/environment/config/boundary/entry[0]/wind-from-east-fps", 1);
|
||||
var wind_from_east_Node = props.globals.getNode("/environment/config/boundary/entry[0]/wind-from-east-fps", 1);
|
||||
wind_from_east_Node.setDoubleValue(0);
|
||||
|
||||
wind_from_north_Node = props.globals.getNode("/environment/config/boundary/entry[0]/wind-from-north-fps", 1);
|
||||
var wind_from_north_Node = props.globals.getNode("/environment/config/boundary/entry[0]/wind-from-north-fps", 1);
|
||||
wind_from_north_Node.setDoubleValue(0);
|
||||
|
||||
wind_from_Node = props.globals.getNode("/environment/config/boundary/entry[0]/wind-from-heading-deg", 1);
|
||||
var wind_from_Node = props.globals.getNode("/environment/config/boundary/entry[0]/wind-from-heading-deg", 1);
|
||||
wind_from_Node.setDoubleValue(0);
|
||||
|
||||
wind_speed_Node = props.globals.getNode("/environment/config/boundary/entry[0]/wind-speed-kt", 1);
|
||||
var wind_speed_Node = props.globals.getNode("/environment/config/boundary/entry[0]/wind-speed-kt", 1);
|
||||
wind_speed_Node.setDoubleValue(0);
|
||||
|
||||
wind_status_Node = props.globals.getNode("/environment/config/enabled", 1);
|
||||
var wind_status_Node = props.globals.getNode("/environment/config/enabled", 1);
|
||||
wind_status_Node.setBoolValue(1);
|
||||
|
||||
ground_vis_Node = props.globals.getNode("/environment/ground-visibility-m", 1);
|
||||
var ground_vis_Node = props.globals.getNode("/environment/ground-visibility-m", 1);
|
||||
ground_vis_Node.setDoubleValue(500);
|
||||
|
||||
ground_thick_Node = props.globals.getNode("/environment/ground-haze-thickness-m" , 1);
|
||||
var ground_thick_Node = props.globals.getNode("/environment/ground-haze-thickness-m" , 1);
|
||||
ground_thick_Node.setDoubleValue(300);
|
||||
|
||||
ground_term_Node = props.globals.getNode("/environment/terminator-relative-position-m" , 1);
|
||||
var ground_term_Node = props.globals.getNode("/environment/terminator-relative-position-m" , 1);
|
||||
ground_term_Node.setDoubleValue(60000);
|
||||
|
||||
|
||||
|
|
|
@ -18,8 +18,6 @@ void main()
|
|||
texel = texture2D(texture, gl_TexCoord[0].st);
|
||||
fragColor = color * texel;
|
||||
|
||||
gl_FragColor = fragColor;
|
||||
|
||||
finalColor.rgb = fog_Func(fragColor.rgb, fogType);
|
||||
gl_FragColor = finalColor;
|
||||
|
||||
|
|
|
@ -2,9 +2,12 @@
|
|||
// Licence: GPL v2
|
||||
// Author: Frederic Bouvier.
|
||||
// Adapted from the paper by F. Policarpo et al. : Real-time Relief Mapping on Arbitrary Polygonal Surfaces
|
||||
// Adapted from the paper and sources by M. Drobot in GPU Pro : Quadtree Displacement Mapping with Height Blending
|
||||
|
||||
#version 120
|
||||
|
||||
#extension GL_ATI_shader_texture_lod : enable
|
||||
|
||||
#define TEXTURE_MIP_LEVELS 10
|
||||
#define TEXTURE_PIX_COUNT 1024 //pow(2,TEXTURE_MIP_LEVELS)
|
||||
#define BINARY_SEARCH_COUNT 10
|
||||
|
|
|
@ -341,7 +341,7 @@
|
|||
<stretch>true</stretch>
|
||||
</hrule>
|
||||
</group>
|
||||
|
||||
|
||||
<group>
|
||||
<layout>hbox</layout>
|
||||
|
||||
|
@ -353,6 +353,7 @@
|
|||
<min>0.0</min>
|
||||
<max>5.0</max>
|
||||
<step>1.0</step>
|
||||
<fraction>0.17</fraction>
|
||||
<property>/sim/rendering/shaders/quality-level</property>
|
||||
<binding>
|
||||
<command>dialog-apply</command>
|
||||
|
@ -369,7 +370,7 @@
|
|||
<property>/sim/rendering/shaders/quality-level</property>
|
||||
</text>
|
||||
</group>
|
||||
|
||||
|
||||
<group>
|
||||
<layout>hbox</layout>
|
||||
<button>
|
||||
|
@ -382,7 +383,7 @@
|
|||
<dialog-name>shaders</dialog-name>
|
||||
</binding>
|
||||
</button>
|
||||
|
||||
|
||||
<group>
|
||||
<layout>vbox</layout>
|
||||
<text>
|
||||
|
@ -416,7 +417,7 @@
|
|||
</text>
|
||||
</group>
|
||||
</group>
|
||||
|
||||
|
||||
<group>
|
||||
<layout>hbox</layout>
|
||||
<text>
|
||||
|
@ -430,11 +431,11 @@
|
|||
<stretch>true</stretch>
|
||||
</hrule>
|
||||
</group>
|
||||
|
||||
|
||||
<group>
|
||||
<layout>hbox</layout>
|
||||
<halign>right</halign>
|
||||
|
||||
|
||||
<text>
|
||||
<label>Snow line</label>
|
||||
<enable>
|
||||
|
@ -465,13 +466,13 @@
|
|||
</enable>
|
||||
<min>0.0</min>
|
||||
<max>5000.0</max>
|
||||
<property>/environment/snow-level-m</property>
|
||||
<property>/sim/rendering/snow-level-m</property>
|
||||
<binding>
|
||||
<command>dialog-apply</command>
|
||||
<object-name>snow-level</object-name>
|
||||
<command>dialog-apply</command>
|
||||
<object-name>snow-level</object-name>
|
||||
</binding>
|
||||
</slider>
|
||||
|
||||
|
||||
<text>
|
||||
<halign>left</halign>
|
||||
<enable>
|
||||
|
@ -488,10 +489,10 @@
|
|||
<label>12345678</label>
|
||||
<format>%.fm</format>
|
||||
<live>true</live>
|
||||
<property>/environment/snow-level-m</property>
|
||||
<property>/sim/rendering/snow-level-m</property>
|
||||
</text>
|
||||
</group>
|
||||
|
||||
|
||||
<group>
|
||||
<layout>hbox</layout>
|
||||
<text>
|
||||
|
@ -510,7 +511,7 @@
|
|||
<stretch>true</stretch>
|
||||
</hrule>
|
||||
</group>
|
||||
|
||||
|
||||
<group>
|
||||
<layout>vbox</layout>
|
||||
<checkbox>
|
||||
|
@ -570,7 +571,7 @@
|
|||
<property>/sim/rendering/mie</property>
|
||||
</text>
|
||||
</group>
|
||||
|
||||
|
||||
<group>
|
||||
<layout>hbox</layout>
|
||||
<halign>right</halign>
|
||||
|
@ -656,7 +657,7 @@
|
|||
<property>/sim/rendering/dome-density</property>
|
||||
</text>
|
||||
</group>
|
||||
|
||||
|
||||
<empty>
|
||||
<stretch>1</stretch>
|
||||
</empty>
|
||||
|
|
|
@ -184,6 +184,7 @@
|
|||
<min>0.0</min>
|
||||
<max>5.0</max>
|
||||
<step>1.0</step>
|
||||
<fraction>0.17</fraction>
|
||||
<property>/sim/rendering/shaders/urban</property>
|
||||
<binding>
|
||||
<command>dialog-apply</command>
|
||||
|
@ -196,6 +197,7 @@
|
|||
<min>0.0</min>
|
||||
<max>5.0</max>
|
||||
<step>1.0</step>
|
||||
<fraction>0.17</fraction>
|
||||
<property>/sim/rendering/shaders/water</property>
|
||||
<binding>
|
||||
<command>dialog-apply</command>
|
||||
|
|
Loading…
Reference in a new issue