You are here: Start » Filter Reference » Image Local Transforms » GradientDirAndPresenceImage
Computes an image of gradient directions mapped to the range from 1 to 255. Zero means "no edge".
Name | Type | Range | Description | |
---|---|---|---|---|
![]() |
inImage | Image | Input image | |
![]() |
inRoi | Region* | Range of output pixels to be computed | |
![]() |
inOperator | GradientMaskOperator | Defines how the gradient is computed | |
![]() |
inEdgeThreshold | Real | 0.01 - ![]() |
Minimum edge magnitude (other pixels will be set to 0) |
![]() |
outDirectionsImage | Image |
Applications
Description
The operation computes the angle of the intensity change direction at each pixel of the inImage. Firstly the selected inOperator is used to obtain two-dimensional gradient vector at each pixel. When this vector length exceeds inEdgeThreshold the angle of the vector is calculated, scaled and stored in outDirectionsImage pixel.
This operation always generates mono image with uint8 pixel type on output, regardless of input image format, with following pixel values:
- When gradient length does not exceed threshold, the value of 0 is stored in pixel.
- When gradient length exceeds threshold, its angle is scaled to range 1...255 and stored in pixel value.
Hardware Acceleration
This operation is optimized for SSE2 technology for pixels of type: UINT8.
This operation supports automatic parallelization for multicore and multiprocessor systems.
Complexity Level
This filter is available on Expert Complexity Level.