Class DetectFiducialSquareImage<T extends ImageGray>
- java.lang.Object
-
- boofcv.alg.fiducial.square.BaseDetectFiducialSquare<T>
-
- boofcv.alg.fiducial.square.DetectFiducialSquareImage<T>
-
public class DetectFiducialSquareImage<T extends ImageGray> extends BaseDetectFiducialSquare<T>
Fiducial which uses images to describe arbitrary binary patterns. When useing this fiducial it's up to the user to select good images which will provide unique orientation and are easily distinguished against other patterns and noise insensitive.
The above image visually shows the fiducials internal coordinate system. The center of the fiducial is the origin of the coordinate system, e.g. all sides are width/2 distance away from the origin. +x is to the right, +y is up , and +z out of the paper towards the viewer.
A good pattern will have thick lines or thick shapes. When detecting the image it's not uncommon for the distortion removal to be off by one or two pixels. So think lines are be completely out of synch. The image should also be chosen so that there is to rotational ambiguity. A perfect circle in the center is an example of a bad fiducial in which orientation can't be uniquely determined.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static classDetectFiducialSquareImage.FiducialDefdescription of an image in 4 different orientations-
Nested classes/interfaces inherited from class boofcv.alg.fiducial.square.BaseDetectFiducialSquare
BaseDetectFiducialSquare.Result
-
-
Constructor Summary
Constructors Constructor and Description DetectFiducialSquareImage(InputToBinary<T> inputToBinary, BinaryPolygonDetector<T> quadDetector, double borderWidthFraction, double minimumBlackBorderFraction, double matchThreshold, java.lang.Class<T> inputType)Configures the fiducial detector
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description intaddPattern(GrayU8 inputBinary, double lengthSide)Adds a new image to the detector.java.util.List<DetectFiducialSquareImage.FiducialDef>getTargets()-
Methods inherited from class boofcv.alg.fiducial.square.BaseDetectFiducialSquare
computeTargetToWorld, configure, getBinary, getBorderWidthFraction, getFound, getInputType, getPoseEstimator, getSquareDetector, process, setVerbose
-
-
-
-
Constructor Detail
-
DetectFiducialSquareImage
public DetectFiducialSquareImage(InputToBinary<T> inputToBinary, BinaryPolygonDetector<T> quadDetector, double borderWidthFraction, double minimumBlackBorderFraction, double matchThreshold, java.lang.Class<T> inputType)
Configures the fiducial detector- Parameters:
matchThreshold- Considered a match if the hamming distance is less than this fraction of the maximum
-
-
Method Detail
-
addPattern
public int addPattern(GrayU8 inputBinary, double lengthSide)
Adds a new image to the detector. Image must be gray-scale and is converted into a binary image using the specified threshold. All input images are rescaled to be square and of the appropriate size. Thus the original shape of the image doesn't matter. Square shapes are highly recommended since that's what the target looks like.- Parameters:
inputBinary- Binary input image pattern. 0 = black, 1 = white.lengthSide- How long one of the sides of the target is in world units.- Returns:
- The ID of the provided image
-
getTargets
public java.util.List<DetectFiducialSquareImage.FiducialDef> getTargets()
-
-
DataMelt 3.0 © DataMelt by jWork.ORG