Package org.hyperonline.hyperlib.vision
Class SkewPairTargetProcessor
- java.lang.Object
-
- org.hyperonline.hyperlib.vision.AbstractTargetProcessor<SkewVisionResult>
-
- org.hyperonline.hyperlib.vision.SkewPairTargetProcessor
-
- All Implemented Interfaces:
TargetProcessor
public class SkewPairTargetProcessor extends AbstractTargetProcessor<SkewVisionResult>
Target processor class which picks out the pair of targets skewed towards each other.
-
-
Constructor Summary
Constructors Constructor Description SkewPairTargetProcessor(SkewVisionConnector connector, int xCrosshairs, int yCrosshairs)
SkewPairTargetProcessor(SkewVisionConnector connector, java.util.function.IntSupplier xCrosshairs, java.util.function.IntSupplier yCrosshairs)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SkewVisionResult
computeResult(java.util.List<org.opencv.core.Rect> targets)
void
writeOutput(org.opencv.core.Mat mat)
Draw overlays on the image.-
Methods inherited from class org.hyperonline.hyperlib.vision.AbstractTargetProcessor
getLastResult, process
-
-
-
-
Constructor Detail
-
SkewPairTargetProcessor
public SkewPairTargetProcessor(SkewVisionConnector connector, int xCrosshairs, int yCrosshairs)
- Parameters:
connector
- VisionConnector for retreiving/publishing the resultxCrosshairs
- X coordinate for the crosshairsyCrosshairs
- Y coordinate for the crosshairs
-
SkewPairTargetProcessor
public SkewPairTargetProcessor(SkewVisionConnector connector, java.util.function.IntSupplier xCrosshairs, java.util.function.IntSupplier yCrosshairs)
- Parameters:
connector
- VisionConnector for retreiving/publishing the resultxCrosshairs
- X coordinate for the crosshairsyCrosshairs
- Y coordinate for the crosshairs
-
-
Method Detail
-
computeResult
public SkewVisionResult computeResult(java.util.List<org.opencv.core.Rect> targets)
- Specified by:
computeResult
in classAbstractTargetProcessor<SkewVisionResult>
- Parameters:
targets
- list of targets to compute- Returns:
- {T}
-
writeOutput
public void writeOutput(org.opencv.core.Mat mat)
Draw overlays on the image. This should give the user some indication of what the result ofTargetProcessor.process(List)
was.- Parameters:
mat
- The image to draw on.
-
-