RenderViewsTesselatedSphere with color information

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

RenderViewsTesselatedSphere with color information

Ber461
So recently I was asked by a fellow researcher whether or not RenderViewsTesselatedSphere could generate snapshots with RGB information from 3D models that had it available. I looked at the source code and apparently the "generation of RGB synthetic clouds when RGB available on mesh" is a planned feature, but not implemented right now.

So after taking a quick look at the VTK API I created a copy of the class with a few changes (PointXYZRGBA as point type, pixel RGB data from the render gets saved to the appropriate point in the cloud, and lightning is disabled for the object so shadows don't alter the color). He tested it and it seemed to work OK, though I don't know if it would support textured VTK models (I think we only tried with plain colored materials).



There are still a couple of bugs. For example, the border points are influenced by the render background (red). Anyway, if you think this would be worth cleaning up the code and making a pull request, I'd like to know.

http://robotica.unileon.es/~victorm/PCL_snapshot_creator_rgb.tar.gz