IPA::Local - methods that produce images where every pixel is a function of pixels in the neighborhood
Contains functions that operate in the vicinity of a pixel, and produce image where every pixel is dependant on the values of the source pixel and the values of its neighbors. The process can be described with the mapping function
|r(i,j),r(i+1,j)...| s = M |... | |r(j+1,i) ... |
where r
and s
are the pixel values in the input and output images, respectively.
Applies the crispening algorithm to IMAGE and returns the result.
Supported types: Byte
Applies Sobel edge detector to IMAGE.
Supported types: Byte
Parameters:
Combination of the integer constants, that mask the pixels in Sobel 3x3 kernel. If the kernel is to be drawn as
| (-1,1) (0,1) (1,1) | | (-1,0) (0,0) (1,0) | | (-1,-1)(0,-1)(1,-1)|
Then the constants mask the following points:
sobelRow - (-1,0),(1,0) sobelColumn - (0,1),(0,-1) sobelNESW - (1,1),(-1,-1) sobelNWSE - (-1,1),(1,-1)
(0,0) point is always masked.
The resulting pixel value is divided to divisor
value after the kernel convolution is applied.
conversionType
and <combineType> parameters described in combine.
Applies GEF algorithm ( first derivative operator for symmetric exponential filter) to IMAGE.
Supported types: Byte
Applies SDEF algorithm ( second derivative operator for symmetric exponential filter) to IMAGE.
Supported types: Byte
Applies Deriche edge detector.
Supported types: Byte
Applies convolution with a custom 3x3 kernel, passed in matrix
.
Supported types: Byte
Parameters:
Array of 9 integers, a 3x3 kernel, to be convoluted with IMAGE. Indexes are:
|0 1 2| |3 4 5| |6 7 8|
If false, the edge pixels ( borders ) not used in the convolution as center pixels. If true, the edge pixels used, and in this case edgecolor
value is used to substitute the pixels outside the image.
Integer value, used for substitution of pixel values outside IMAGE, when expandEdges
parameter is set to 1.
The resulting pixel value is divided to divisor
value after the kernel convolution is applied.
See combine
See combine
Performs adaptive thresholding with median filter with window dimensions w
and h
.
Applies a union find algorithm selected by method
. The only implemented method is average-based region grow ( 'ave' string constant ). Its only parameter is threshold
, integer value of the balance merger function.
Supported types: Byte
Perform binary hysteresis thresholding of Byte image with two thresholds, thr0 and thr1. A pixel is set to 1, if its value is larger than thr1 or if it is larger than thr0 and the pixel is adjacent to already marked pixels.
Default value of neighborhood is 8.
Supported types: Byte
Generates a square image of the given SIZe and populates with with gaussian function with given SIGMA.
Generates a square image of the given SIZe and populates with with inverse gaussian function with given SIGMA.
This function computes a two-dimensional gradient (magnitude and direction) of an image, using two convolution kernels. The magnitude is computed as the vector magnitude of the output of the two kernels, and the direction is computed as the angle between the two orthogonal gradient vectors.
The convolution kernels are (currently limited to) 3x3 masks for calculating separate vertical and horizontal derivatives.
(Copyright (c) 1988 by the University of Arizona Digital Image Analysis Lab).
First part of the Canny edge detector (without ridge strength selection). The ridge strength must be supplied by the user.
Applies non-maximal suppression to the image, and replaces all non-maximal pixels with the clear
color, and maximal with set
color.
Convolves a given image with a gaussian, where the latter is calculated with the given size and square root of sigma_square.
First part of the Lindeberg edge detector (without scale selection). The scale must be supplied by the user. size
is used in generation of the gaussian kernel. mul
is the custom multiply factor to the calclated ridge strength, the maximum absolute value to the principal curvatures. anorm
selects whether the Laplacian blob response should be included ( false
) ), or suppressed ( true
).
Convolves IMAGE with the given KERNEL.
Creates a map from IMAGE where white pixels are assigned to spots where image crosses the zero plane. The zero level is 0 by default, but can be changed by setting the cmp
argument.