Rendering or visualising 3D images
How do I get to visualize or 3D image in python. I have been able to create a pipeline to get point clouds from pair of stereo frames using openCV. I am writing them as PCD files after calculating disparity and reprojecting image to 3D. It takes lot of time to write it to a file.
Is it possible to get something like this.
https://www.youtube.com/watch?v=B2pEb...
what things I will need to do to achieve that? I am using python 3 and openCV 3
There has to be some kind of support for OpenGL in Python (yes, there is... http://pyopengl.sourceforge.net).
Rainbow colouring by distance is also pretty straightforward (I have C++ code for it anyway: https://gist.github.com/sjhalayka/1cb...).
Are you sure you need to use Python?
Yes, I need to get it done with Python. I have seen there is something called Viz that can be used with C++ but unfortunately it is not available for Python. So it seems I need to look at rendering point cloud with OpenGL.
I recommend that you buy The Red Book, The Blue Book, and The Orange Book. You can use OpenGL 1.x (ie.
glVertex3f()
-- http://www.glprogramming.com/red/), which is super easy to use, or OpenGL 4.x (ie.glDrawArrays()
), which lies a little closer to the metal, and is a little more difficult to use.If you need any help with OpenGL, my email address is available in my profile -- [email protected]
Thank you, I will look into that.
Found a great set of tutorials at: http://pyopengl.sourceforge.net/conte...
The Gamedev.net forums are also a great resource.