Smooth Viewer

Back to Tutorials

1. Simple Viewer 3. Device Handler 1 2  3  4  5  6  7  8  9  10  11  12  13  14  15  16



So after successfully setting up the basic viewer application, now it's time to get serious.

The smooth method applies a spatial and temporal smooth to the depth image that has three main advantages: i) reduces the amount and size of the "holes" in the image, ii) reduces the noise per pixel and iii) smooths the objects' edge.

This feature is quite simple to get it working, yet really handy for many applications! But because it envolves some image processing techniques, the CPU load will be higher. From here on we will only cover the new stuff, so if you have any doubt just head back to the previous example to find your way back here. The header file is similar to the one from simple viewer and you should understand it clearly now. In the .cpp file we find some small changes from the previous example: As you can see, again we have the basics, the event listener and the start method. To use the smoothed version of the depth image there are two subtle changes from the viewer. Firstly you tell ViiM to enable smooth by setting the enableSmooth method true, which is false by default (line 33).

Lastly instead of the previous getColorPixels method, we use getSmoothDepthPixels (line 49), so both raw depth image and smoothed depth image are shown for comparison purposes. If you follow the rest of the steps on the viewer example you'll get it working just fine. To try this example head to the apps folder, ViiM_OF_Samples and select your operating system. See the differences between the two modes for yourself!

1. Simple Viewer 3. Device Handler 1 2  3  4  5  6  7  8  9  10  11  12  13  14  15  16

Back to Tutorials