Class GradientSparseSobel_U8
java.lang.Object
boofcv.alg.filter.derivative.impl.GradientSparseSobel_U8
- All Implemented Interfaces:
SparseImageGradient<GrayU8,
,GradientValue_I32> SparseImageOperator<GrayU8>
public class GradientSparseSobel_U8
extends Object
implements SparseImageGradient<GrayU8,GradientValue_I32>
Sparse computation of the sobel gradient operator.
-
Constructor Summary
ConstructorDescriptionGradientSparseSobel_U8
(ImageBorder_S32<GrayU8> border) Specifies how border pixels are handled. -
Method Summary
Modifier and TypeMethodDescriptioncompute
(int x, int y) Computes the gradient at the specified point.boolean
isInBounds
(int x, int y) Checks to see if the entire sample region is contained inside the image or not.void
Specifies the image being processed.
-
Constructor Details
-
GradientSparseSobel_U8
Specifies how border pixels are handled. If null then the border is not handled.- Parameters:
border
- how borders are handled
-
-
Method Details
-
compute
Description copied from interface:SparseImageGradient
Computes the gradient at the specified point.- Specified by:
compute
in interfaceSparseImageGradient<GrayU8,
GradientValue_I32> - Parameters:
x
- x-axis pixel coordinatey
- y-axis pixel coordinate- Returns:
- Gradient at that point.
-
getGradientType
- Specified by:
getGradientType
in interfaceSparseImageGradient<GrayU8,
GradientValue_I32>
-
setImage
Description copied from interface:SparseImageOperator
Specifies the image being processed.- Specified by:
setImage
in interfaceSparseImageOperator<GrayU8>
- Parameters:
input
- Image being processed
-
isInBounds
public boolean isInBounds(int x, int y) Description copied from interface:SparseImageOperator
Checks to see if the entire sample region is contained inside the image or not. Depending on the implementation it might be able to handle out of bounds pixels or not.- Specified by:
isInBounds
in interfaceSparseImageOperator<GrayU8>
-