Ask Your Question
0

shadows of the household objects in gazebo

asked 2011-07-13 07:53:41 -0600

Hello, does anybody know how to spawn complex objects in gazebo and still render the shadows nicely?

I am using the meshes from the household database and spawning urdfs in gazebo. However, I get the following error:

gazebo: /tmp/buildd/ros-cturtle-visualization-common-1.2.0/debian/ros-cturtle-
visualization-common/opt/ros/cturtle/stacks/visualization_common/ogre/build
/ogre_src_v1-7-1/OgreMain/src/OgreShadowCaster.cpp:348: 
virtual void Ogre::ShadowCaster::generateShadowVolume(Ogre::EdgeData*, const   
Ogre::HardwareIndexBufferSharedPtr&, const Ogre::Light*,  
std::vector<Ogre::ShadowRenderable*, Ogre::STLAllocator<Ogre::ShadowRenderable*,  
 Ogre::CategorisedAllocPolicy<(Ogre::MemoryCategory)0u> > >&, long unsigned int): Assertion 
`numIndices <= indexBuffer->getNumIndexes() && "Index buffer overrun while generating 
shadow volume!! " "You must increase the size of the shadow index buffer."' failed.
[gazebo-1] process has died [pid 2190, exit code -6].
log files: /afs/athena.mit.edu/user/m/i/mitko/.ros/log/7bb452c2-ad85-11e0-9e9f-0025900a1f7d
/gazebo-1*.log

By asking around I found that if I turn the shadows off in the world file this is fixed (and it is- I tried), but then the rendering is quite ugly and I actually need the rendering to be good (in order to export some videos). Does anybody know how I can increase the shadow index buffer, or use different shadowing technique? I tried:

<shadowTechnique>textureAdditive</shadowTechnique>

but the error persists.

Also, any ideas if I can turn the shadows off of only the household objects?

Thank you.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2011-07-13 09:53:11 -0600

hsu gravatar image

updated 2011-07-13 09:56:45 -0600

try

<shadowTechnique>stencilModulative</shadowTechnique>
<shadows>true</shadows>

See if that helps.

Also, there isn't a way to turn off shadows on a per-object basis right now.

edit flag offensive delete link more

Comments

Thanks, hsu, for the quick answer. However, the same error persists but it has strange behavior - if I don't do anything gazebo stays alive - if I try to move the viewpoint or to start rviz, gazebo crashes.
Dimitar Simeonov gravatar imageDimitar Simeonov ( 2011-07-13 10:07:02 -0600 )edit
hm, how many vertices/faces are in your simulation world meshes? Can you try reducing the number down a bit? Or switch to diamondback?
hsu gravatar imagehsu ( 2011-07-13 10:55:46 -0600 )edit
I cannot decrease the number because these are the household_database meshes. I will try diamondback and let you know how it works.
Dimitar Simeonov gravatar imageDimitar Simeonov ( 2011-07-14 03:59:05 -0600 )edit
hsu, just to let you know - it didn't work in diamondback - as soon as i try to change the initial viewpoint gazebo crashes with the same error. I will use shadowless simulation for now.
Dimitar Simeonov gravatar imageDimitar Simeonov ( 2011-07-14 06:40:41 -0600 )edit
is it possible for you to post your world file so I can see if I can replicate it? Have you tried on a different machine? what graphics card are you using? thanks.
hsu gravatar imagehsu ( 2011-07-14 06:45:13 -0600 )edit
Thanks for trying this - I posted the files you'll need at http://people.csail.mit.edu/mitko/gazebo_stuff/ look at README_hsu for instructions about the files - it is pretty much the wg.world with some urdf objects created from the household_database objects. I haven't tried another machine yet.
Dimitar Simeonov gravatar imageDimitar Simeonov ( 2011-07-14 09:36:19 -0600 )edit
I couldn't find the exact name of the video card but it is NVIDIA with 336 GPU cores and 1GB of memory
Dimitar Simeonov gravatar imageDimitar Simeonov ( 2011-07-14 09:44:40 -0600 )edit
what does lspci -v say about your video card? Sounds quite modern, probably not the problem. Can you tar up the files or put in a repository? getting thousands of files over http is not as easy as I thought. thanks.
hsu gravatar imagehsu ( 2011-07-14 10:47:10 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2011-07-13 07:53:41 -0600

Seen: 707 times

Last updated: Jul 13 '11