Color Threshold (Color»Color Threshold)

NI Vision Assistant

Color Threshold (Color»Color Threshold)

Applies a threshold to the three planes of a color image and places the result into an 8-bit image.

  • Color Model—Color encoding scheme: RGB, HSL, HSV, or HSI.
  • Preview Color—Color used to highlight the pixels selected by the threshold Min and Max values. Default value is red.
  • Histogram
    LinearDisplays the histograms in a linear scale.
    LogarithmicDisplays the histograms in a logarithmic scale. Use the logarithmic scale if the linear values are too small to view using a linear scale.
  • Red/Hue—Thresholding range for the red or hue plane (depending on Color Model). Any pixel values not included in this range are reset to zero in the destination image. You can modify the Min and Max values by clicking and dragging on the blue and red markers on the histogram.
  • Green/Saturation—Thresholding range for the green or saturation plane (depending on Color Model). Any pixel values not included in this range are reset to zero in the destination image. You can modify the Min and Max values by clicking and dragging on the blue and red markers on the histogram.
  • Blue/Luminance/Value/Intensity—Thresholding range for the blue, luminance, value, or intensity plane (depending on Color Model). Any pixel values not included in this range are reset to zero in the destination image. You can modify the Min and Max values by clicking and dragging on the blue and red markers on the histogram.
    Note  You can use the Hue indicator to select all pixels with a certain hue when you set Color Model to HSL, HSV, or HSI. Select a specific hue that you want to isolate in the image using the ROI tools. The histograms display the pixels that you need to select in order to isolate all of pixels with that hue. Drag the blue and red markers on the histograms until all pixels with that hue are selected.
  • Min—Lowest pixel value included in the manual threshold range. For manual thresholds, you can adjust the blue cursor on the histogram to set the lower bound for this range.
  • Max—Highest pixel value included in the manual threshold range. For manual thresholds, you can adjust the red cursor on the histogram to set the upper bound for this range.
  • In/Out Range (Valid for HSL, HSV, or HSI)
    In—Hue is included in the threshold range. Threshold range: [Min, Max]
    Out—Hue is not included in the threshold range. Threshold range: [0, Min] [Max, 255]
Tip  You can display the histogram of a portion of an image by drawing an ROI around the area of interest. The local histogram gives you valuable information about the threshold range you can select to keep or reject certain parts of the image.

Related Topics

Grayscale Threshold (Grayscale»Threshold)

Thresholding an image