Class ImplOrientationAverageGradientIntegral<T extends ImageGray<T>,G extends GradientValue>
java.lang.Object
boofcv.alg.feature.orientation.OrientationIntegralBase<T,G>
boofcv.alg.feature.orientation.impl.ImplOrientationAverageGradientIntegral<T,G>
- All Implemented Interfaces:
OrientationIntegral<T>
,RegionOrientation
public class ImplOrientationAverageGradientIntegral<T extends ImageGray<T>,G extends GradientValue>
extends OrientationIntegralBase<T,G>
Estimates the orientation of a region by computing the image derivative from an integral image. The derivative along each axis is summed up and the angle computed from that.
-
Field Summary
Fields inherited from class boofcv.alg.feature.orientation.OrientationIntegralBase
g, ii, kernelWidth, objectRadiusToScale, period, sampleRadius, sampleWidth, scale, weights, weightSigma
-
Constructor Summary
ConstructorDescriptionImplOrientationAverageGradientIntegral
(double radiusToScale, int sampleRadius, double period, int kernelWidth, double weightSigma, Class<T> imageType) -
Method Summary
Modifier and TypeMethodDescriptiondouble
compute
(double c_x, double c_y) Computes the orientation of a region about its center.protected double
computeUnweighted
(double tl_x, double tl_y, double samplePeriod, SparseImageGradient<T, G> g) Compute the gradient while checking for border conditionsprotected double
computeWeighted
(double tl_x, double tl_y, double samplePeriod, SparseImageGradient<T, G> g) Compute the gradient while checking for border conditionscopy()
Creates a copy which is functionally identicalMethods inherited from class boofcv.alg.feature.orientation.OrientationIntegralBase
getImageType, setImage, setObjectRadius
-
Constructor Details
-
ImplOrientationAverageGradientIntegral
public ImplOrientationAverageGradientIntegral(double radiusToScale, int sampleRadius, double period, int kernelWidth, double weightSigma, Class<T> imageType) - Parameters:
sampleRadius
- Radius of the region being considered in terms of Wavelet samples. Typically 6.weightSigma
- Sigma for weighting distribution. Zero for unweighted.
-
-
Method Details
-
compute
public double compute(double c_x, double c_y) Description copied from interface:RegionOrientation
Computes the orientation of a region about its center.- Parameters:
c_x
- Center of the region in image pixels.c_y
- Center of the region in image pixels.- Returns:
- Orientation in radians. Angle zero points along x-axis and pi/2 along y-axis.
-
computeUnweighted
protected double computeUnweighted(double tl_x, double tl_y, double samplePeriod, SparseImageGradient<T, G> g) Compute the gradient while checking for border conditions -
computeWeighted
protected double computeWeighted(double tl_x, double tl_y, double samplePeriod, SparseImageGradient<T, G> g) Compute the gradient while checking for border conditions -
copy
Description copied from interface:RegionOrientation
Creates a copy which is functionally identical
-