<?xml version='1.0' encoding='UTF-8'?>
<PropertyList>
  <name>Effects/procedural-light</name>
  <parameters>
    <texture n="0">
      <type>white</type>
    </texture>
    <light_color_base_r type="float">1.0</light_color_base_r>
    <light_color_base_g type="float">0.0</light_color_base_g>
    <light_color_base_b type="float">0.0</light_color_base_b>
    <light_color_center_r type="float">1.0</light_color_center_r>
    <light_color_center_g type="float">1.0</light_color_center_g>
    <light_color_center_b type="float">1.0</light_color_center_b>
    <intensity_scale type="float">1.0</intensity_scale>
    <pointing_x type="float">-1.0</pointing_x>
    <pointing_y type="float">0.0</pointing_y>
    <pointing_z type="float">0.0</pointing_z>
    <is_directional type="bool">false</is_directional>
    <is_strobe type="bool">false</is_strobe>
    <inner_angle type="float">0.2</inner_angle>
    <outer_angle type="float">0.4</outer_angle>
    <zero_angle type="float">0.7</zero_angle>
    <outer_gain type="float">0.5</outer_gain>
    <visibility>
      <use>/environment/ground-visibility-m</use>
    </visibility>
    <avisibility>
      <use>/environment/visibility-m</use>
    </avisibility>
    <lthickness>
      <use>/environment/ground-haze-thickness-m</use>
    </lthickness>
    <terrain_alt>
      <use>/environment/mean-terrain-elevation-m</use>
    </terrain_alt>
    <eye_alt>
      <use>/sim/rendering/eye-altitude-m</use>
    </eye_alt>
    <terminator>
      <use>/environment/terminator-relative-position-m</use>
    </terminator>
  </parameters>
  <technique n="19">
    <scheme>als-lighting</scheme>
    <predicate>
      <and>
        <or>
          <less-equal>
            <value type="float">2.0</value>
            <glversion/>
          </less-equal>
          <and>
            <extension-supported>GL_ARB_shader_objects</extension-supported>
            <extension-supported>GL_ARB_shading_language_100</extension-supported>
            <extension-supported>GL_ARB_vertex_shader</extension-supported>
            <extension-supported>GL_ARB_fragment_shader</extension-supported>
          </and>
        </or>
      </and>
    </predicate>
    <pass>
      <lighting>true</lighting>
      <material>
        <active>
          <use>material/active</use>
        </active>
        <ambient>
          <use>material/ambient</use>
        </ambient>
        <diffuse>
          <use>material/diffuse</use>
        </diffuse>
        <specular>
          <use>material/specular</use>
        </specular>
        <emissive>
          <use>material/emissive</use>
        </emissive>
        <shininess>
          <use>material/shininess</use>
        </shininess>
        <color-mode>
          <use>material/color-mode</use>
        </color-mode>
      </material>
      <blend>
        <active>
          <use>blend/active</use>
        </active>
        <source>
          <use>blend/source</use>
        </source>
        <destination>
          <use>blend/destination</use>
        </destination>
      </blend>
      <shade-model>
        <use>shade-model</use>
      </shade-model>
      <cull-face>
        <use>cull-face</use>
      </cull-face>
      <rendering-hint>
        <use>rendering-hint</use>
      </rendering-hint>
      <render-bin>
        <bin-number>111</bin-number>
        <bin-name>DepthSortedBin</bin-name>
      </render-bin>
      <texture-unit>
        <!-- The texture unit is always active because the shaders expect
             that. -->
        <unit>0</unit>
        <active>
          <use>texture[0]/active</use>
        </active>
        <type>
          <use>texture[0]/type</use>
        </type>
        <image>
          <use>texture[0]/image</use>
        </image>
        <filter>
          <use>texture[0]/filter</use>
        </filter>
        <wrap-s>
          <use>texture[0]/wrap-s</use>
        </wrap-s>
        <wrap-t>
          <use>texture[0]/wrap-t</use>
        </wrap-t>
        <internal-format>
          <use>texture[0]/internal-format</use>
        </internal-format>
      </texture-unit>
      <depth>
        <write-mask>false</write-mask>
      </depth>
      <vertex-program-two-side>false</vertex-program-two-side>
      <program>
        <vertex-shader>Shaders/ALS/light.vert</vertex-shader>
        <fragment-shader>Shaders/ALS/light.frag</fragment-shader>
        <fragment-shader>Shaders/ALS/noise.frag</fragment-shader>
        <fragment-shader>Shaders/ALS/hazes.frag</fragment-shader>
      </program>
      <uniform>
        <name>light_color_base_r</name>
        <type>float</type>
        <value>
          <use>light_color_base_r</use>
        </value>
      </uniform>
      <uniform>
        <name>light_color_base_g</name>
        <type>float</type>
        <value>
          <use>light_color_base_g</use>
        </value>
      </uniform>
      <uniform>
        <name>light_color_base_b</name>
        <type>float</type>
        <value>
          <use>light_color_base_b</use>
        </value>
      </uniform>
      <uniform>
        <name>light_color_center_r</name>
        <type>float</type>
        <value>
          <use>light_color_center_r</use>
        </value>
      </uniform>
      <uniform>
        <name>light_color_center_g</name>
        <type>float</type>
        <value>
          <use>light_color_center_g</use>
        </value>
      </uniform>
      <uniform>
        <name>light_color_center_b</name>
        <type>float</type>
        <value>
          <use>light_color_center_b</use>
        </value>
      </uniform>
      <uniform>
        <name>intensity_scale</name>
        <type>float</type>
        <value>
          <use>intensity_scale</use>
        </value>
      </uniform>
      <uniform>
        <name>pointing_x</name>
        <type>float</type>
        <value>
          <use>pointing_x</use>
        </value>
      </uniform>
      <uniform>
        <name>pointing_y</name>
        <type>float</type>
        <value>
          <use>pointing_y</use>
        </value>
      </uniform>
      <uniform>
        <name>pointing_z</name>
        <type>float</type>
        <value>
          <use>pointing_z</use>
        </value>
      </uniform>
      <uniform>
        <name>inner_angle</name>
        <type>float</type>
        <value>
          <use>inner_angle</use>
        </value>
      </uniform>
      <uniform>
        <name>outer_angle</name>
        <type>float</type>
        <value>
          <use>outer_angle</use>
        </value>
      </uniform>
      <uniform>
        <name>zero_angle</name>
        <type>float</type>
        <value>
          <use>zero_angle</use>
        </value>
      </uniform>
      <uniform>
        <name>outer_gain</name>
        <type>float</type>
        <value>
          <use>outer_gain</use>
        </value>
      </uniform>
      <uniform>
        <name>visibility</name>
        <type>float</type>
        <value>
          <use>visibility</use>
        </value>
      </uniform>
      <uniform>
        <name>avisibility</name>
        <type>float</type>
        <value>
          <use>avisibility</use>
        </value>
      </uniform>
      <uniform>
        <name>hazeLayerAltitude</name>
        <type>float</type>
        <value>
          <use>lthickness</use>
        </value>
      </uniform>
      <uniform>
        <name>eye_alt</name>
        <type>float</type>
        <value>
          <use>eye_alt</use>
        </value>
      </uniform>
      <uniform>
        <name>terminator</name>
        <type>float</type>
        <value>
          <use>terminator</use>
        </value>
      </uniform>
      <uniform>
        <name>texture</name>
        <type>sampler-2d</type>
        <value type="int">0</value>
      </uniform>
      <uniform>
        <name>is_directional</name>
        <type>bool</type>
        <value>
          <use>is_directional</use>
        </value>
      </uniform>
      <uniform>
        <name>is_strobe</name>
        <type>bool</type>
        <value>
          <use>is_strobe</use>
        </value>
      </uniform>
    </pass>
  </technique>
</PropertyList>
