ThresholdToRegion_Dynamic
Thresholds an image relatively to the average pixel value in a local rectangular neighborhood.
Applications:Useful in case of uneven illumination.
Syntax
C++
C#
Python
def ThresholdToRegion_Dynamic( inImage: Image, outRegion: Region, /, *, inRoi: Region | None = None, inSourceRoi: Region | None = None, inRadiusX: int = 5, inRadiusY: int | None = None, inMinRelativeValue: float | None = 5.0, inMaxRelativeValue: float | None = None, inHysteresis: float = 0.0, diagBaseImage: Image | None = None ) -> None
Parameters
| Name | Type | Range | Default | Description | |
|---|---|---|---|---|---|
![]() |
inImage | Image | Input image | ||
![]() |
inRoi | Region | None | None | Region in which pixels are written | |
![]() |
inSourceRoi | Region | None | None | Region from which pixels are read | |
![]() |
inRadiusX | int | 0 - 65535 | 5 | Horizontal radius of internal mean blur |
![]() |
inRadiusY | int | None | 0 - 65535 | None | Vertical radius of internal mean blur (Auto = inRadiusX) |
![]() |
inMinRelativeValue | float | None | 5.0 | Minimum relative value of a pixel that is considered foreground (Auto = -INF) | |
![]() |
inMaxRelativeValue | float | None | None | Maximum relative value of a pixel that is considered foreground (Auto = +INF) | |
![]() |
inHysteresis | float | 0.0 - ![]() |
0.0 | Defines how much the threshold criteria are lowered for pixels neighboring with other foreground pixels |
![]() |
outRegion | Region | Output region | ||
![]() |
diagBaseImage | Image | None | None | Diagnostic blurred image. |




