Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Suggestion: drop VTK for VIZ and use simple OpenGL

Hello there,

would it be possible to remove the whole VTK dependency from OpenCV and create a simple OpenGL based basic vizualization instead that comes per default with the opencv package?

Reasons: 1. Not having the balast of this VTK library. Compiling it is not fun. Also when someone just wants to vizualize sth quickly it is not quickly set up. 2. VTK pointcloud renderer is slow. To be fair, thats my experience when using it with PCL - it took about 60ms on a high end desktop pc until a dense pointcloud with 1920*1200 points (about 2.3 Million 3d points) was rendered. Just for uploading and rendering it. This is so slow. 3. You can create really fast renderers that directly upload your cv::Mat 3d vertices an opengl vertex buffer array. I have written a very simple prototype that used simple OpenGL code and renders it very fast.

Here i prepared a desktop recording of a scene with 19201200 image resolution. In this video i do the following: Reading 19201200 stereo images from disk Estimating a depthmap from those images using block matching Calculating 3d vertices from the depth map uploading to a pointcloud viewer that i have written

Here the video: https://www.youtube.com/watch?v=-Bw_m85EAto&feature=youtu.be If someone wants to know (at the begining i used a blocksize of 19 and at the end of the video i changed it interactively to 47 - with 19 blocksize it takes 50ms and with 47 blocksize the whole pipeline takes 80ms)

What users get: - high performance rendering of point cloud sequences for example from a stereo block matching result - no vtk dependency and viz should then come per default in opencv

Does OpenCV use VTK else where? I mean is it such a useful library for opencv? In my opinion, when someone wants to use VTK for vizualization, then VTK should be a dependency of the end user project but not of opencv library.

This is not a question, but rather a discussion. What do you thing? I thought maybe for the coming opencv 4.0 release this would be a nice idea.

Suggestion: drop VTK for VIZ and use simple OpenGL

Hello there,

would it be possible to remove the whole VTK dependency from OpenCV and create a simple OpenGL based basic vizualization instead that comes per default with the opencv package?

Reasons: 1. Not having the balast of this VTK library. Compiling it is not fun. Also when someone just wants to vizualize sth quickly it is not quickly set up. 2. VTK pointcloud renderer is slow. To be fair, thats my experience when using it with PCL - it took about 60ms on a high end desktop pc until a dense pointcloud with 1920*1200 1920x1200 points (about 2.3 Million 3d points) was rendered. Just for uploading and rendering it. This is so slow. 3. You can create really fast renderers that directly upload your cv::Mat 3d vertices an opengl vertex buffer array. I have written a very simple prototype that used simple OpenGL code and renders it very fast.

Here i prepared a desktop recording of a scene with 19201200 1920x1200 image resolution. In this video i do the following: Reading 19201200 stereo images from disk disk with 1920x1200 resolution Estimating a depthmap from those images using block matching Calculating 3d vertices from the depth map uploading to a pointcloud viewer that i have written

Here the video: https://www.youtube.com/watch?v=-Bw_m85EAto&feature=youtu.be If someone wants to know (at the begining i used a blocksize of 19 and at the end of the video i changed it interactively to 47 - with 19 blocksize it takes 50ms and with 47 blocksize the whole pipeline takes 80ms)

What users get: - high performance rendering of point cloud sequences for example from a stereo block matching result - no vtk dependency and viz should then come per default in opencv

Does OpenCV use VTK else where? I mean is it such a useful library for opencv? In my opinion, when someone wants to use VTK for vizualization, then VTK should be a dependency of the end user project but not of opencv library.

This is not a question, but rather a discussion. What do you thing? I thought maybe for the coming opencv 4.0 release this would be a nice idea.

Suggestion: drop VTK for VIZ and use simple OpenGL

Hello there,

would it be possible to remove the whole VTK dependency from OpenCV and create a simple OpenGL based basic vizualization instead that comes per default with the opencv package?

Reasons: 1. Not having the balast of this VTK library. Compiling it is not fun. Also when someone just wants to vizualize sth quickly it is not quickly set up. 2. VTK pointcloud renderer is slow. To be fair, thats my experience when using it with PCL - it took about 60ms on a high end desktop pc until a dense pointcloud with 1920x1200 points (about 2.3 Million 3d points) was rendered. Just for uploading and rendering it. This is so slow. 3. You can create really fast renderers that directly upload your cv::Mat 3d vertices an opengl vertex buffer array. I have written a very simple prototype that used simple OpenGL code and renders it very fast.

Here i prepared a desktop recording of a scene with 1920x1200 image resolution. In this video i do the following: Reading stereo images from disk with 1920x1200 resolution Estimating a depthmap from those images using block matching Calculating 3d vertices from the depth map uploading to a pointcloud viewer that i have written

Here the video: https://www.youtube.com/watch?v=-Bw_m85EAto&feature=youtu.be https://youtu.be/-Bw_m85EAto If someone wants to know (at the begining i used a blocksize of 19 and at the end of the video i changed it interactively to 47 - with 19 blocksize it takes 50ms and with 47 blocksize the whole pipeline takes 80ms)

What users get: - high performance rendering of point cloud sequences for example from a stereo block matching result - no vtk dependency and viz should then come per default in opencv

Does OpenCV use VTK else where? I mean is it such a useful library for opencv? In my opinion, when someone wants to use VTK for vizualization, then VTK should be a dependency of the end user project but not of opencv library.

This is not a question, but rather a discussion. What do you thing? I thought maybe for the coming opencv 4.0 release this would be a nice idea.