0
$\begingroup$

Rosanswers logo

Hi there,

I'm wondering if there is some easy way to increase the number of faces plot on RVIZ when, as an example, displaying a visualization_msgs::Marker::SPHERE. I suspect that it's an Ogre issue rather an Rviz setting..

Have a look to this pic https://farm9.staticflickr.com/8648/15895679946_3e7e039afb_c.jpg

image description

Any thoughts?

Bye, Augusto


Originally posted by Augusto Luis Ballardini on ROS Answers with karma: 430 on 2018-03-01

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

Got it. The mesh is located under:

/opt/ros/kinetic/share/rviz/ogre_media/models/rviz_sphere.mesh 

or your cloned repository under the models folder and it is loaded from shape.cpp (github link)

The only issue is to create a new mesh, which can actually be done using Blender and some tools. I used:

  • blender-2.79a-linux-glibc219-x86_64 ; from blender, I've created the new sphere (just press the Create tab and then Sphere, then click F6 to change the number of "faces". Then Export > Ogre3D (activate the add-on following the instructions of blender2ogre). Save the sphereHD.mesh.xml
  • blender2ogre blender2ogre (follow install instructions from the readme)
  • OgreXmlConverter only for windows :-( Use it to convert the sphereHD.mesh.xml to something that Ogre is able to use. Then "change the filename under shape.cpp and compile RVIZ again". Ok it's not the best solution I know, but that's a start :-)

Some images:

From Blender...

image description

Sphere rendered inside RVIZ before:

image description

Sphere rendered inside RVIZ afteR: image description

I've also used as reference: https://answers.ros.org/question/9770/display-an-ogre-mesh-and-material-in-rviz/ https://github.com/OGRECave/blender2ogre http://wiki.ogre3d.org/OgreXmlConverter http://wiki.ogre3d.org/Blender+to+Ogre


Originally posted by Augusto Luis Ballardini with karma: 430 on 2018-03-02

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.