<?xml version="1.0" ?>
<sdf version="1.6">
  <world name="default">

  <!-- Light Source -->
  <light type="directional" name="sun">
    <cast_shadows>true</cast_shadows>
    <pose>0 0 0 0.0 0.0 0.0</pose>
    <diffuse>1.0 1.0 1.0 1.0</diffuse>
    <specular>0.2 0.2 0.2 1</specular>
    <direction>-1.0 0.0 -0.2</direction>
  </light>

    <!-- A ground plane -->
    <include>
      <uri>model://ground_plane</uri>
    </include>

    <model name="heightmap">
      <static>true</static>
      <link name="link">
        <collision name="collision">
          <geometry>
            <heightmap>
              <uri>file://media/materials/textures/heightmap_bowl.png</uri>
              <size>129 129 10</size>
              <pos>0 0 0</pos>
            </heightmap>
          </geometry>
        </collision>
        <visual name="visual_abcedf">
          <geometry>
            <heightmap>
              <use_terrain_paging>false</use_terrain_paging>
              <texture>
                <diffuse>file://media/materials/textures/dirt_diffusespecular.png</diffuse>
                <normal>file://media/materials/textures/flat_normal.png</normal>
                <size>1</size>
              </texture>
              <texture>
                <diffuse>file://media/materials/textures/grass_diffusespecular.png</diffuse>
                <normal>file://media/materials/textures/flat_normal.png</normal>
                <size>1</size>
              </texture>
              <texture>
                <diffuse>file://media/materials/textures/fungus_diffusespecular.png</diffuse>
                <normal>file://media/materials/textures/flat_normal.png</normal>
                <size>1</size>
              </texture>
              <blend>
                <min_height>2</min_height>
                <fade_dist>5</fade_dist>
              </blend>
              <blend>
                <min_height>4</min_height>
                <fade_dist>5</fade_dist>
              </blend>
              <uri>file://media/materials/textures/heightmap_bowl.png</uri>
              <size>129 129 10</size>
              <pos>0 0 0</pos>
            </heightmap>
          </geometry>
        </visual>
      </link>
    </model>

    <!-- model with two wide-angle cameras, with and without lens flare plugin -->
    <model name="wide_angle_cameras_near_heightmap">
      <static>true</static>
      <pose>0 2 5.2 0 0 0</pose>
      <link name="link">
        <visual name="visual">
          <geometry>
            <box>
              <size>0.1 0.1 0.1</size>
            </box>
          </geometry>
        </visual>
        <sensor name="camera_sensor_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
          <plugin name="lensflare" filename="libLensFlareSensorPlugin.so"/>
        </sensor>
        <sensor name="camera_sensor_without_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
        </sensor>
      </link>
    </model>

    <!-- model with two wide-angle cameras, with and without lens flare plugin -->
    <model name="wide_angle_cameras_above_heightmap">
      <static>true</static>
      <pose>0 2 11.0 0 0 0</pose>
      <link name="link">
        <visual name="visual">
          <geometry>
            <box>
              <size>0.1 0.1 0.1</size>
            </box>
          </geometry>
        </visual>
        <sensor name="camera_sensor_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
          <plugin name="lensflare" filename="libLensFlareSensorPlugin.so"/>
        </sensor>
        <sensor name="camera_sensor_without_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
        </sensor>
      </link>
    </model>

    <!-- A box that should occlude a camera's lens flare -->
    <include>
      <uri>model://brick_box_3x1x3</uri>
      <pose>5 12 5 0 0 1.57</pose>
      <name>brick_box_low</name>
    </include>

    <!-- model with two wide-angle cameras, with and without lens flare plugin -->
    <model name="wide_angle_cameras_occluded_low">
      <static>true</static>
      <pose>0 12 5.2 0 0 0</pose>
      <link name="link">
        <visual name="visual">
          <geometry>
            <box>
              <size>0.1 0.1 0.1</size>
            </box>
          </geometry>
        </visual>
        <sensor name="camera_sensor_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
          <plugin name="lensflare" filename="libLensFlareSensorPlugin.so"/>
        </sensor>
        <sensor name="camera_sensor_without_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
        </sensor>
      </link>
    </model>

    <!-- A box that should occlude a camera's lens flare -->
    <include>
      <uri>model://brick_box_3x1x3</uri>
      <pose>5 12 10 0 0 1.57</pose>
      <name>brick_box_high</name>
    </include>

    <!-- model with two wide-angle cameras, with and without lens flare plugin -->
    <model name="wide_angle_cameras_occluded_high">
      <static>true</static>
      <pose>0 12 11.0 0 0 0</pose>
      <link name="link">
        <visual name="visual">
          <geometry>
            <box>
              <size>0.1 0.1 0.1</size>
            </box>
          </geometry>
        </visual>
        <sensor name="camera_sensor_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
          <plugin name="lensflare" filename="libLensFlareSensorPlugin.so"/>
        </sensor>
        <sensor name="camera_sensor_without_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
        </sensor>
      </link>
    </model>

    <!-- A box that should occlude a camera's lens flare -->
    <include>
      <uri>model://brick_box_3x1x3</uri>
      <pose>0 11 20 0 0 0</pose>
      <name>brick_box_higher_side</name>
    </include>

    <!-- model with two wide-angle cameras, with and without lens flare plugin -->
    <model name="wide_angle_cameras_occluded_higher">
      <static>true</static>
      <pose>0 12 21.0 0 0 0</pose>
      <link name="link">
        <visual name="visual">
          <geometry>
            <box>
              <size>0.1 0.1 0.1</size>
            </box>
          </geometry>
        </visual>
        <sensor name="camera_sensor_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
          <plugin name="lensflare" filename="libLensFlareSensorPlugin.so"/>
        </sensor>
        <sensor name="camera_sensor_without_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>25</update_rate>
          <visualize>true</visualize>
        </sensor>
      </link>
    </model>

    <!-- model with two wide-angle cameras with slow update rates, with and without lens flare plugin -->
    <model name="slow_wide_angle_cameras">
      <static>true</static>
      <pose>0 12 11.0 0 0 0</pose>
      <link name="link">
        <visual name="visual">
          <geometry>
            <box>
              <size>0.1 0.1 0.1</size>
            </box>
          </geometry>
        </visual>
        <sensor name="camera_sensor_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>1</update_rate>
          <visualize>true</visualize>
          <plugin name="lensflare" filename="libLensFlareSensorPlugin.so"/>
        </sensor>
        <sensor name="camera_sensor_without_lensflare" type="wideanglecamera">
          <camera>
            <horizontal_fov>3.14159</horizontal_fov>
            <image>
              <width>320</width>
              <height>240</height>
            </image>
            <clip>
              <near>0.1</near>
              <far>100</far>
            </clip>
            <lens>
              <type>equidistant</type>
              <scale_to_hfov>true</scale_to_hfov>
              <cutoff_angle>1.5707</cutoff_angle>
              <env_texture_size>512</env_texture_size>
            </lens>
          </camera>
          <always_on>1</always_on>
          <update_rate>1</update_rate>
          <visualize>true</visualize>
        </sensor>
      </link>
    </model>
  </world>
</sdf>
