ThresholdingSegmentation This example demonstrates how to use the
SoThresholdingProcessing to create a binary image.
DESCRIPTION:
Segmentation is a very important step of an image processing workflow. This is where objects to identify in the scene are isolated in a binary or label image.
This example shows how to create a binary image from an input grayscale image with a classic thresholding operator. The input image is shown with the resulting thresholded image as overlay.
-
The input grayscale image is loaded in an SoImageDataAdapter object.
-
A binary image is generated as output of the SoThresholdingProcessing engine.
-
A scene graph is built to display the original image in a viewer with the binary image as overlay.
NOTE:
-
Before the segmentation step a pre-processing can be previously applied to enhance the input image, for instance with a denoising step .
-
For more information about image segmentation, see section Image Segmentation.
SEE ALSO
SoThresholdingProcessing
SCREENSHOT:
FILES:
-
ImageViz/GettingStarted/02.1.ThresholdingSegmentation.cxx