Class FeatureSelectUniform<Point>
java.lang.Object
boofcv.alg.feature.detect.selector.FeatureSelectUniform<Point>
- All Implemented Interfaces:
FeatureSelectLimit<Point>
- Direct Known Subclasses:
FeatureSelectUniform.F32,FeatureSelectUniform.F64,FeatureSelectUniform.I16
public abstract class FeatureSelectUniform<Point>
extends Object
implements FeatureSelectLimit<Point>
Attempts to select features uniformly across the image. This is done by breaking the image up into a grid and
selecting a specific number randomly from each grid cell.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classImplementation forPoint2D_F32static classImplementation forPoint2D_F64static classImplementation forPoint2D_I16static classInfo for each cell -
Field Summary
FieldsModifier and TypeFieldDescriptionConfiguration for uniformly selecting a grid -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract FeatureSelectUniform.Info<Point>getGridCell(Point p) Returns the grid cell that contains the pointvoidselect(int imageWidth, int imageHeight, @Nullable FastAccess<Point> prior, FastAccess<Point> detected, int limit, FastArray<Point> selected) Selects features inside the image.
-
Field Details
-
configUniform
Configuration for uniformly selecting a grid -
rand
-
-
Constructor Details
-
FeatureSelectUniform
public FeatureSelectUniform()
-
-
Method Details
-
select
public void select(int imageWidth, int imageHeight, @Nullable @Nullable FastAccess<Point> prior, FastAccess<Point> detected, int limit, FastArray<Point> selected) Description copied from interface:FeatureSelectLimitSelects features inside the image.- Specified by:
selectin interfaceFeatureSelectLimit<Point>- Parameters:
imageWidth- Width of the image the features were detected inimageHeight- Height of the image the features were detected inprior- (Input) Locations of previously detected featuresdetected- (Input) Locations of newly detected featureslimit- (Input) The maximum number of new features detectedselected- (Output) Selected features. Element count not exceed the limit. Reset on every call.
-
getGridCell
Returns the grid cell that contains the point
-