Updated ftclib.

Fixed CameraStreamProcessor bug to prevent adding RectInfo if the processor is not enabled.
Made the CameraStreamProcessor easier to use.
This commit is contained in:
Titan Robotics Club
2024-10-13 13:10:01 -07:00
parent 54de20bce1
commit 02dc2b49c5
4 changed files with 29 additions and 4 deletions

View File

@ -223,6 +223,7 @@ public class FtcTest extends FtcTeleOp
case VISION_TEST:
if (robot.vision != null)
{
robot.vision.setCameraStreamEnabled(true);
if (robot.vision.vision != null)
{
exposure = robot.vision.vision.getCurrentExposure();
@ -258,6 +259,7 @@ public class FtcTest extends FtcTeleOp
if (robot.vision != null && robot.vision.rawColorBlobVision != null)
{
robot.globalTracer.traceInfo(moduleName, "Enabling FtcRawEocvVision.");
robot.vision.setCameraStreamEnabled(true);
robot.vision.setRawColorBlobVisionEnabled(true);
colorThresholds = robot.vision.getRawColorBlobThresholds();
colorThresholdIndex = 0;