ThresholdToRegion_Color
Creates a region containing image pixels with values close to the given color.
Applications:Color analysis with a given reference color.
Syntax
C++
C#
Python
def ThresholdToRegion_Color( inImage: Image, inHysteresis: float, outRegion: Region, /, *, inRoi: Region | None = None, inRgbColor: Pixel = Pixel(0, 0, 0, 0), inChromaAmount: float = 0.7, inMaxDifference: float = 5.0 ) -> None
Parameters
| Name | Type | Range | Default | Description | |
|---|---|---|---|---|---|
![]() |
inImage | Image | Input image | ||
![]() |
inRoi | Region | None | None | Region of interest | |
![]() |
inRgbColor | Pixel | Pixel(0, 0, 0, 0) | Color to compare the image to | |
![]() |
inChromaAmount | float | 0.0 - 1.0 | 0.7 | Proportion of chromatic information in distance computation |
![]() |
inMaxDifference | float | 0.0 - ![]() |
5.0 | Maximum difference between image pixel and model color |
![]() |
inHysteresis | float | 0.0 - ![]() |
Defines how much the difference criterium is lowered for pixels neighboring with other foreground pixels | |
![]() |
outRegion | Region | Output region |
Hardware Acceleration
This operation is optimized for SSE2 technology for pixels of types: 1xUINT8, 3xUINT8.
This operation is optimized for NEON technology for pixels of types: 1xUINT8, 3xUINT8.
This operation supports automatic parallelization for multicore and multiprocessor systems.



