Ogre 3D bad performance in ROS?
Dear all,
I have the following problem: Iam writing a simple ros node with Ogre 3D (1.9) visualization (e.g. some data from certain messages is used to define the position and orientation of some simulated entities), in accordance to: https://github.com/Unnar3/rosOgre
However, I get very bad performance (~15 frames), even when rendering a scene without any geometry. Has anybody had a similar experience?
I tried the following:
- Disabling VSYNC in Ogre config and nvidia-settings
- Two different rendering approaches 1) The ros node does not subscribe to / publish any messages and is basically just calling renderOneFrame from Ogre 2) The ros node does not subscribe to / publish any messages and directly calls startRendering from Ogre
- Compiling the code with release flags
All above implementations suffer the same bad performance, using Ubuntu 14.04 and ROS Indigo. The same code runs on the same machine on Windows (without the ROS framework) with OpenGL at >1000 fps.
FYI: I will also ask this question in the Ogre forums, just wanted to have feedback for my problem from both communities.
EDIT: Implementing a small sample application in OpenGL outside of ROS performs as expected.
Asked by OgreROS on 2016-09-15 02:21:19 UTC
Comments
Do you have a dedicated graphics card? Do you have the drivers for it installed and enabled?
Asked by ahendrix on 2016-09-15 02:29:39 UTC
Yes - Iam using a NVidia graphics card with the 352.63 driver
Asked by OgreROS on 2016-09-15 04:31:21 UTC
Can you display what you're trying to display in RViz (which uses Ogre)? I think it would be easier depending on what you're trying to do.
Asked by Airuno2L on 2016-09-15 07:29:08 UTC
Hi, have a look at the link above for the Ogre code I'm using (I just removed the pcl stuff). I do not use RViz, I use Ogre separately (we need some functionality from 1.9 where ROS comes with Ogre 1.8).
Asked by OgreROS on 2016-09-15 08:18:45 UTC
Not an answer obviously, but RViz in Kinetic uses Ogre 1.9. See REP-3 - Platforms by Distribution - Kinetic Kame. And Jade on Trusty uses 1.8, but on > Trusty it uses 1.9 again.
Asked by gvdhoorn on 2016-09-15 08:55:21 UTC
It seems kind of unlikely that ROS is the culprit here. Have you tried running the same test code on Ubuntu without ROS to compare?
Asked by ahendrix on 2016-09-15 09:25:40 UTC