use of boofcv.alg.fiducial.aztec.AztecPyramid in project BoofCV by lessthanoptimal.
the class AztecCodePreciseDetector method process.
@Override
public void process(T gray) {
// Reset and initialize
allMarkers.reset();
detected.clear();
failed.clear();
// Detect finder patterns
inputToBinary.process(gray, binary);
detectorPyramids.process(gray, binary);
// Attempt to decode candidate markers
List<AztecPyramid> pyramids = detectorPyramids.getFound().toList();
if (verbose != null)
verbose.println("Total pyramids found: " + pyramids.size());
for (int locatorIdx = 0; locatorIdx < pyramids.size(); locatorIdx++) {
AztecPyramid pyramid = pyramids.get(locatorIdx);
if (verbose != null)
verbose.println("Considering pyramid at: " + pyramid.get(0).center);
AztecCode marker = allMarkers.grow();
if (decoder.process(pyramid, gray, marker)) {
detected.add(marker);
} else {
failed.add(marker);
}
}
}
Aggregations