Gazebo | Ignition | Community
Ask Your Question
0

Warped camera data from a new Gazebo/ROS install [closed]

asked 2015-01-15 20:20:24 -0600

SL Remy gravatar image

updated 2015-01-20 17:37:33 -0600

Hello! I have a fresh Indigo install on 14.04 with Gazebo2 installed from debs:

wget http://packages.osrfoundation.org/gazebo.key -O - | sudo apt-key add - 
sudo apt-get -y install ros-indigo-gazebo-ros-pkgs

But I'm noticing some odd data from the camera sensor on a hector_quadrotor_demo. I've never run 2.X before and did not notice this in Gazebo 1.9, so I can't say if it's something that is directly related to 2.X or not.

Using (as per suggestion)

DISPLAY=:1 gazebo /usr/share/gazebo-2.2/worlds/camera.world

and then

gztopic view /gazebo/default/camera/link/camera/image

I see the following

image description

When the same tool is used to view the image topic for the hector world though, a warped image is seen.

image description

The world file for the hector world is below:

<?xml version="1.0" ?>
<sdf version="1.4">
  <world name="default">
    <scene>
      <ambient>0.5 0.5 0.5 1</ambient>
      <background>0.5 0.5 0.5 1</background>
      <shadows>false</shadows>
    </scene>
    <physics type="ode">
      <gravity>0 0 -9.8</gravity>
      <ode>
        <solver>
          <type>quick</type>
          <iters>10</iters>
          <sor>1.3</sor>
        </solver>
        <constraints>
          <cfm>0.0</cfm>
          <erp>0.2</erp>
          <contact_max_correcting_vel>100.0</contact_max_correcting_vel>
          <contact_surface_layer>0.001</contact_surface_layer>
        </constraints>
      </ode>
      <real_time_update_rate>1000</real_time_update_rate>
      <max_step_size>0.001</max_step_size>
    </physics>
    <include>
      <uri>model://ground_plane</uri>
    </include>
    <include>
      <uri>model://willowgarage</uri>
    </include>
    <light type="directional" name="my_light">
      <pose>0 0 30 0 0 0</pose>
      <diffuse>.5 .5 .5 1</diffuse>
      <specular>.1 .1 .1 1</specular>
      <attenuation>
        <range>200</range>
      </attenuation>
      <direction>0 0 -1</direction>
      <cast_shadows>false</cast_shadows>
    </light>
  </world>
</sdf>
edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by SL Remy
close date 2015-12-08 07:04:32.383804

Comments

Can you look in ~/.gazebo/ogre.log for any errors or exceptions? Can you also try disabling shadows (click on "Scene" in the "World" tab, then disable shadows in the property list)?

nkoenig gravatar imagenkoenig ( 2015-01-20 14:04:41 -0600 )edit

Compiler error: unknown error in hector_materials.material(4): token "shading" is not recognized Compiler error: unknown error in hector_materials.material(29): token "lighting" is not recognized Compiler error: unknown error in hector_materials.material(80): token "lighting" is not recognized Compiler error: unknown error in hector_materials.material(96): token "lighting" is not recognized

SL Remy gravatar imageSL Remy ( 2015-01-20 16:35:12 -0600 )edit

Looks like the shadows are already off in the world file though

SL Remy gravatar imageSL Remy ( 2015-01-20 17:40:19 -0600 )edit

If it's easy for you, I'd try using Gazebo4. I'll have to try this with gazebo2 to see if I can reproduce the problem.

nkoenig gravatar imagenkoenig ( 2015-01-21 12:43:14 -0600 )edit

I ran your world file in Gazebo4, and it looked fine. This only means that there is either a problem with Gazebo2, or there is something wrong with your particular setup (hardware, drivers, etc). I'll try gazebo2 next.

nkoenig gravatar imagenkoenig ( 2015-01-21 14:22:32 -0600 )edit

I will try Gazebo4 as well

SL Remy gravatar imageSL Remy ( 2015-01-22 21:53:21 -0600 )edit

Hasn't been as easy as I'd hoped. This is taking a while to iron out the installation steps for Gazebo4 and Indigo

SL Remy gravatar imageSL Remy ( 2015-01-26 13:40:40 -0600 )edit

1 Answer

Sort by » oldest newest most voted
0

answered 2015-01-16 09:13:06 -0600

nkoenig gravatar image

I assume the normal render window looks fine, correct?

Can you try something a bit easier?

  1. Run: gazebo worlds/camera.world
  2. When the GUI appears, press CTRL-t to open the topic visualizer.
  3. Select one of the camera image topics, should be /gazebo/defualt/camera/link/camera/image
  4. Does the image look correct? If so, try to fiddle with the environment (add objects, move the camera, etc) to see where it breaks.
edit flag offensive delete link more

Question Tools

Stats

Asked: 2015-01-15 20:20:24 -0600

Seen: 436 times

Last updated: Jan 20 '15