![]() |
IPSDK
4_1_0_2
IPSDK : Image Processing Software Development Kit
|
Apply hysteresis thresholding to an image. More...
| IPSDKIPLBINARIZATION_API ipsdk::image::ImagePtr | ipsdk::imaproc::bin::darkHysteresisThreshold2dImg (const ipsdk::image::ImageConstPtr &pInImg, const ipsdk::ipReal64 highSeedThreshold, const ipsdk::ipReal64 highPropagationThreshold) |
| wrapper function for dark Hysteresis thresholding to an image More... | |
| IPSDKIPLBINARIZATION_API ipsdk::image::ImagePtr | ipsdk::imaproc::bin::lightHysteresisThreshold2dImg (const ipsdk::image::ImageConstPtr &pInImg, const ipsdk::ipReal64 lowSeedThreshold, const ipsdk::ipReal64 lowPropagationThreshold) |
| wrapper function for light Hysteresis thresholding to an image More... | |
| IPSDKIPLBINARIZATION_API ipsdk::image::ImagePtr | ipsdk::imaproc::bin::hysteresisThreshold2dImg (const ipsdk::image::ImageConstPtr &pInImg, const ipsdk::ipReal64 lowSeedThreshold, const ipsdk::ipReal64 highSeedThreshold, const ipsdk::ipReal64 lowPropagationThreshold, const ipsdk::ipReal64 highPropagationThreshold) |
| wrapper function for Apply hysteresis thresholding to an image More... | |
| IPSDKIPLBINARIZATION_API void | ipsdk::imaproc::bin::hysteresisThreshold2dImg (const ipsdk::image::ImageConstPtr &pInImg, const ipsdk::ipReal64 lowSeedThreshold, const ipsdk::ipReal64 highSeedThreshold, const ipsdk::ipReal64 lowPropagationThreshold, const ipsdk::ipReal64 highPropagationThreshold, const ipsdk::eNeighborhood2dType &inOptNeighborhood2d, const image::ImagePtr &pOutBinImg) |
| wrapper function for Apply hysteresis thresholding to an image More... | |
Apply hysteresis thresholding to an image.
Hysteresis threshold algorithm applies two thresholds
and
on the output image.
is the most restrictive threshold and yields a seed image
, used to propagate the marked features in
, obtained by thresholding the input image by
. This algorithm is commonly used in edge detection such as Canny edge detector.
The aim of this threshold is to preserve the features in
containing a seed in
.
The algorithm needs 4 thresholds: the minimum and maximum thresholds
and
to compute the seed image
and the minimum and maximum thresholds
and
to compute the image
, used for the propagation.
To simplify the algorithm parametrization, several wrappers are defined to apply this threshold:
and
,
and
being automatically set to the image buffer type minimum value. This allows to select dark features using darker seeds on light background.
and
,
and
being automatically set to the image buffer type maximum value. This allows to select light features using lighter seeds on dark background.
Here is an example of dark and light hysteresis threshold applied to a gray scale input image. The intensities of each area are indicated we used
and
for the dark threshold and
and
fot the light threshold:
The features and seeds intensities may be higher than the minimum image intensity and lower than the maximum image intensity. The hysteresisThreshold2dImg wrapper allows to handle this case, illustrated by the following figure. In this example, the background have an intensity of 50, the two little white circles have an intensity of 255, the intensity of the central main ellipse equals 96 and the two lighter ellipses inside have an intensity of 192 (left) and 128 (right). Finally, the intensity of the contour of the main ellipse varies from 12 to 44. The threshold used for the calculation are:
,
and
.
Attribute description for algorithm :
| Name | ToolTip | Default Initializer |
|---|---|---|
| ipsdk::imaproc::attr::InImg | [Input] image for processing operation | X |
| ipsdk::imaproc::attr::InHysteresisParams | [Input] Parameters for hysteresis threshold | X |
| ipsdk::imaproc::attr::InOptNeighborhood2d | [Input optional] neighborhood 2d type for operation | X |
| ipsdk::imaproc::attr::OutOptWk1BinImg | [Output Optional] Temporary working image for algorithm | X |
| ipsdk::imaproc::attr::OutOptWk1LabelImg | [Output Optional] Temporary working image for algorithm | X |
| ipsdk::imaproc::attr::OutBinImg | [Output] binary image for processing operation | ipsdk::imaproc::duplicateInOut (_pOutBinImg, _pInImg, image::eImageBufferType::eIBT_Binary) |
Global rule description for algorithm :
(ipsdk::imaproc::matchSize (_pInImg,_pOutBinImg) &&
(ipsdk::processor::ifIsSet (
_pOutOptWk1LabelImg, (
ipsdk::imaproc::matchSize (_pInImg,_pOutOptWk1LabelImg)))) &&
(ipsdk::processor::ifIsSet (
_pOutOptWk1LabelImg, (
ipsdk::imaproc::matchSize (_pInImg,_pOutOptWk1LabelImg)))))
| IPSDKIPLBINARIZATION_API ipsdk::image::ImagePtr ipsdk::imaproc::bin::darkHysteresisThreshold2dImg | ( | const ipsdk::image::ImageConstPtr & | pInImg, |
| const ipsdk::ipReal64 | highSeedThreshold, | ||
| const ipsdk::ipReal64 | highPropagationThreshold | ||
| ) |
wrapper function for dark Hysteresis thresholding to an image
| ipsdk::processor::IPSDKBaseProcessingException | on failure |
| IPSDKIPLBINARIZATION_API ipsdk::image::ImagePtr ipsdk::imaproc::bin::lightHysteresisThreshold2dImg | ( | const ipsdk::image::ImageConstPtr & | pInImg, |
| const ipsdk::ipReal64 | lowSeedThreshold, | ||
| const ipsdk::ipReal64 | lowPropagationThreshold | ||
| ) |
wrapper function for light Hysteresis thresholding to an image
| ipsdk::processor::IPSDKBaseProcessingException | on failure |
| IPSDKIPLBINARIZATION_API ipsdk::image::ImagePtr ipsdk::imaproc::bin::hysteresisThreshold2dImg | ( | const ipsdk::image::ImageConstPtr & | pInImg, |
| const ipsdk::ipReal64 | lowSeedThreshold, | ||
| const ipsdk::ipReal64 | highSeedThreshold, | ||
| const ipsdk::ipReal64 | lowPropagationThreshold, | ||
| const ipsdk::ipReal64 | highPropagationThreshold | ||
| ) |
wrapper function for Apply hysteresis thresholding to an image
| ipsdk::processor::IPSDKBaseProcessingException | on failure |
| IPSDKIPLBINARIZATION_API void ipsdk::imaproc::bin::hysteresisThreshold2dImg | ( | const ipsdk::image::ImageConstPtr & | pInImg, |
| const ipsdk::ipReal64 | lowSeedThreshold, | ||
| const ipsdk::ipReal64 | highSeedThreshold, | ||
| const ipsdk::ipReal64 | lowPropagationThreshold, | ||
| const ipsdk::ipReal64 | highPropagationThreshold, | ||
| const ipsdk::eNeighborhood2dType & | inOptNeighborhood2d, | ||
| const image::ImagePtr & | pOutBinImg | ||
| ) |
wrapper function for Apply hysteresis thresholding to an image
| ipsdk::processor::IPSDKBaseProcessingException | on failure |
1.8.14