Home | Tutorials | Wiki | Issues
Ask Your Question
3

No shadows or lights in Gazebo

asked 2018-11-20 04:22:01 -0500

RandC gravatar image

Hi there!

I'm having trouble setting up a light in Gazebo. I tried with sunlight, directional light and spot light, and the results of each of those are quite similar, something like this.

image description

I don't know what am I doing wrong, but I tried on another computer with the same settings and they work properly.

I'm using Ubuntu 16.04 LTS with ROS Kinetic

Greetings.

edit retag flag offensive close merge delete

5 Answers

Sort by ยป oldest newest most voted
1

answered 2018-12-16 09:01:22 -0500

windblow gravatar image

I've seen this happening with every graphics card except nvidia.

edit flag offensive delete link more

Comments

You are right. I wonder why this error still happens and it has been lasted half a year.

littleghost gravatar imagelittleghost ( 2019-02-25 22:03:19 -0500 )edit

Could you tell me if you have fixed it out on an Intel GPU's PC?

littleghost gravatar imagelittleghost ( 2019-02-26 06:28:17 -0500 )edit

I have same issue with AMD GPU and gazebo 9.x, so it's still here.

windblow gravatar imagewindblow ( 2019-05-03 08:11:49 -0500 )edit

Are there any errors reported in ~/.gazebo/ogre.log ?

mogumbo gravatar imagemogumbo ( 2019-05-08 12:27:13 -0500 )edit

No errors, log is mostly the same as nvidia one.

windblow gravatar imagewindblow ( 2019-05-14 13:46:25 -0500 )edit

I can't duplicate the problem here. I got my employer to give me sudo for switching graphics adapters so I was able to try my laptop's Intel graphics. A basic gazebo .world with a "sun" light works for me on Intel. I'm using Gazebo 9.8.0-1~bionic on Ubuntu 18.04.

mogumbo gravatar imagemogumbo ( 2019-05-16 10:36:54 -0500 )edit

Can you check Device Name in your ogre.log? Still have no success on multiple Intel/AMD machines.

windblow gravatar imagewindblow ( 2019-08-20 15:27:43 -0500 )edit

Here's the same issue on bitbucket. Maybe if it gets more votes we would manage to draw some attention to the problem. https://bitbucket.org/osrf/gazebo/iss...

windblow gravatar imagewindblow ( 2019-08-20 15:32:17 -0500 )edit
0

answered 2019-04-20 04:17:48 -0500

Actually, I'm having the same problem. When the Intel graphic card is used Gazebo is not able to render the shadows, on the other hand, with an Nvidia card the issue disappears.

The worst thing is that gazebo is not returning any error or warning

gazebo --verbose
Gazebo multi-robot simulator, version 10.1.0
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
Gazebo multi-robot simulator, version 10.1.0
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://127.0.0.1:11345
[Msg] Publicized address: 192.168.1.77
[Msg] Connected to gazebo master @ http://127.0.0.1:11345
[Msg] Publicized address: 192.168.1.77

Is there anyone that can explain to me why there is this problem?

edit flag offensive delete link more
0

answered 2019-05-07 22:47:45 -0500

littleghost gravatar image

I find that, if you compile gazebo yourself, then will not meet this problem.

edit flag offensive delete link more

Comments

What graphic card do you use?

AchmadFathoni gravatar imageAchmadFathoni ( 2019-05-22 20:41:08 -0500 )edit

An normal Intel Integrated Graphics 550.

littleghost gravatar imagelittleghost ( 2019-05-22 22:32:46 -0500 )edit

Well I also use Intel GPU and install Gazebo from source but no luck. Object doesn't stop light so there is no shadow.

AchmadFathoni gravatar imageAchmadFathoni ( 2019-05-22 23:00:14 -0500 )edit
0

answered 2019-07-02 08:52:35 -0500

Carolina68 gravatar image

I hhave got the same problem with Ubuntu 18.04.01 + ROS Melodic. My solution is to switch the graphic card from Intel HD Graphics to Nvidia Quadro M1200 on my computer, the problem is sovled and now Gazebo functions normally.

edit flag offensive delete link more
0

answered 2018-11-20 12:04:04 -0500

chapulina gravatar image

I've seen this happening when Gazebo can't find some material resources it needs. Could you try sourcing the setup file before launching Gazebo?

You can find the file as follows:

find /usr -name setup.sh

Then source it like this for example:

. /usr/local/share/gazebo/setup.sh
edit flag offensive delete link more

Comments

I tried to do that, but the sourcing is not clear to me. Should I write "source /usr/share/gazebo/setup.sh"? Because if so, it doesn't work...

RandC gravatar imageRandC ( 2018-11-23 02:50:35 -0500 )edit

Yeah that's what you should do. Run that, and then run Gazebo in the same terminal...

chapulina gravatar imagechapulina ( 2018-11-25 21:34:51 -0500 )edit

Also, if you run Gazebo in verbose mode, do you see any errors? "gazebo --verbose"

chapulina gravatar imagechapulina ( 2018-11-25 21:35:29 -0500 )edit

No error whatsoever. I sourced the path like you said, and then ran Gazebo --verbose. This is the output: Gazebo multi-robot simulator, version 7.14.0 Copyright (C) 2012 Open Source Robotics Foundation. Released under the Apache 2 License. http://gazebosim.org [Msg] Waiting for master. [Msg] Connected to gazebo master @ http://127.0.0.1:11345 [Msg] Publicized address: 192.168.1.73 [Msg] Connected to gazebo master @ http://127.0.0.1:11345 [Msg] Publicized address: 192.168.1.73

RandC gravatar imageRandC ( 2018-11-26 02:53:58 -0500 )edit

Anyone? I'm still having trouble...

RandC gravatar imageRandC ( 2018-12-10 02:38:15 -0500 )edit

this remains a problem, the proposed solution does not solve it

mhubii gravatar imagemhubii ( 2019-04-05 04:39:40 -0500 )edit
Login/Signup to Answer

Question Tools

3 followers

Stats

Asked: 2018-11-20 04:22:01 -0500

Seen: 1,751 times

Last updated: Jul 02