I - Input image type.D - Image derivative type.public class GeneralFeatureDetector<I extends boofcv.struct.image.ImageGray,D extends boofcv.struct.image.ImageGray>
extends java.lang.Object
Detects features which are local maximums and/or local minimums in the feature intensity image.
A list of pixels to exclude as candidates can be provided. Image derivatives need to be computed
externally and provided as needed. The passed in GeneralFeatureIntensity is used to determine if local
maximums or minimums should be detected.
If a maximum number of features is specified then the N most intense features are returned. By default all found features are returned. Set to a value ≤ 0 to detect all features.
| Modifier and Type | Field and Description |
|---|---|
protected boofcv.struct.QueueCorner |
excludeMaximum |
protected boofcv.struct.QueueCorner |
excludeMinimum |
protected NonMaxSuppression |
extractor |
protected boofcv.struct.QueueCorner |
foundMaximum |
protected boofcv.struct.QueueCorner |
foundMinimum |
protected GeneralFeatureIntensity<I,D> |
intensity |
protected int |
maxFeatures |
protected SelectNBestFeatures |
selectBest |
| Modifier | Constructor and Description |
|---|---|
protected |
GeneralFeatureDetector() |
|
GeneralFeatureDetector(GeneralFeatureIntensity<I,D> intensity,
NonMaxSuppression extractor)
Specifies which algorithms to use and configures the detector.
|
| Modifier and Type | Method and Description |
|---|---|
boofcv.struct.image.GrayF32 |
getIntensity() |
boofcv.struct.QueueCorner |
getMaximums()
Returns a list of all the found maximums.
|
boofcv.struct.QueueCorner |
getMinimums()
Returns a list of all the found maximums.
|
boolean |
getRequiresGradient()
If the image gradient is required for calculations.
|
boolean |
getRequiresHessian()
If the image Hessian is required for calculations.
|
float |
getThreshold()
Returns the current feature extraction threshold.
|
boolean |
isDetectMaximums()
true if it will detector local maximums
|
boolean |
isDetectMinimums()
true if it will detector local minimums
|
void |
process(I image,
D derivX,
D derivY,
D derivXX,
D derivYY,
D derivXY)
Computes point features from image gradients.
|
void |
setExcludeMaximum(boofcv.struct.QueueCorner exclude)
Specify points which are excluded when detecting maximums
|
void |
setExcludeMinimum(boofcv.struct.QueueCorner exclude)
Specify points which are excluded when detecting maximums
|
void |
setMaxFeatures(int numFeatures)
Turns on select best features and sets the number it should return.
|
void |
setSearchRadius(int radius)
Species the search radius for the feature
|
void |
setThreshold(float threshold)
Changes feature extraction threshold.
|
protected boofcv.struct.QueueCorner foundMaximum
protected boofcv.struct.QueueCorner foundMinimum
protected boofcv.struct.QueueCorner excludeMaximum
protected boofcv.struct.QueueCorner excludeMinimum
protected SelectNBestFeatures selectBest
protected int maxFeatures
protected NonMaxSuppression extractor
protected GeneralFeatureIntensity<I extends boofcv.struct.image.ImageGray,D extends boofcv.struct.image.ImageGray> intensity
public GeneralFeatureDetector(GeneralFeatureIntensity<I,D> intensity, NonMaxSuppression extractor)
intensity - Computes how much like the feature the region around each pixel is.extractor - Extracts the corners from intensity imageprotected GeneralFeatureDetector()
public void process(I image, D derivX, D derivY, D derivXX, D derivYY, D derivXY)
image - Original image.derivX - image derivative in along the x-axis. Only needed if getRequiresGradient() is true.derivY - image derivative in along the y-axis. Only needed if getRequiresGradient() is true.derivXX - Second derivative. Only needed if getRequiresHessian() ()} is true.derivXY - Second derivative. Only needed if getRequiresHessian() ()} is true.derivYY - Second derivative. Only needed if getRequiresHessian() ()} is true.public void setMaxFeatures(int numFeatures)
numFeatures - Return at most this many features, which are the best.public boolean getRequiresGradient()
public boolean getRequiresHessian()
public boofcv.struct.image.GrayF32 getIntensity()
public void setThreshold(float threshold)
threshold - The new feature extraction threshold.public float getThreshold()
public void setExcludeMaximum(boofcv.struct.QueueCorner exclude)
exclude - List of points being excludedpublic boofcv.struct.QueueCorner getMaximums()
public void setExcludeMinimum(boofcv.struct.QueueCorner exclude)
exclude - List of points being excludedpublic boofcv.struct.QueueCorner getMinimums()
public boolean isDetectMinimums()
public boolean isDetectMaximums()
public void setSearchRadius(int radius)
radius - Radius in pixels