danielp | b913fa7 | 2013-03-03 06:23:20 +0000 | [diff] [blame] | 1 | package org.spartanrobotics;
|
| 2 |
|
| 3 | import edu.wpi.first.wpijavacv.WPIColorImage;
|
| 4 |
|
| 5 | /**
|
| 6 | * Vision target recognizer.
|
| 7 | *
|
| 8 | * @author jerry
|
| 9 | */
|
| 10 | public interface Recognizer {
|
| 11 |
|
| 12 | /**
|
| 13 | * Sets the HSV filter to allow H in [minHue .. maxHue], S >= minSat,
|
| 14 | * V >= minVal.
|
| 15 | */
|
| 16 | void setHSVRange(int minHue, int maxHue, int minSat, int minVal);
|
| 17 |
|
| 18 | int getHueMin();
|
| 19 | int getHueMax();
|
| 20 | int getSatMin();
|
| 21 | int getValMin();
|
| 22 |
|
| 23 | /** Enables/disables windows to view intermediate stages, for tuning. */
|
| 24 | void showIntermediateStages(boolean enable);
|
| 25 |
|
| 26 | /**
|
| 27 | * Processes a camera image, returning an image to display for targeting
|
| 28 | * and debugging, e.g. with cross-hairs and marked targets.
|
| 29 | *<p>
|
| 30 | * SIDE EFFECTS: May modify cameraImage.
|
| 31 | */
|
| 32 | Target processImage(WPIColorImage cameraImage);
|
| 33 | }
|