Overview
This example demonstrates how to use the IMAQ Color Threshold function to produce a binary image from a color image.
Description
The Color Threshold example shows you how to produce a binary image from a color image using either the RGB or HSL color threshold mode. With either threshold mode, you can set the minimum and maximum thresholding for each of the respective components via controls on the front panel. There are two example images provided in the example.
Hardware and Software Requirements
Vision Development Module
Steps to Implement or Execute Code
- Find the example under Help >> Find Examples >> Toolkit and Modules >> Vision >> Color >> Color Threshold.vi
- Run the VI
- Change the Test Image to use different images with the same threshold ranges
- Adjust the sliders to change the threshold ranges. Notice that HSL is a better Threshold Color Mode to find specific colors with lighting variations
Clemens | Technical Support Engineer | National Instruments