Skip to content
CrocoDocs
Starter GuideProgrammingEngineeringDesignPortfolio
Documentation

Introduction

IntroductionBIOBUZZ game overview

Getting started

Getting startedBlocksOnBot JavaAndroid StudioYour first OpModeJava basicsMotors and servosNonblocking codeDebugging robot code

Control systems

Control systemsJoystick mappingField-centric mecanum drivePID controlFeedforwardFlywheel velocity controlSystem identificationMotion profilingKalman filterLow-pass filter

Autonomous

AutonomousTimed and encoder movementOdometryLocalization troubleshootingMotion planningReliable autonomous sequencesPure PursuitSensor fusionAuto to TeleOp handoff

Season topics

Season topicsProjectile mathematicsTurret aimingShooting on the move

Code practices

Code practicesNaming conventionsCode organizationLoop timing and bulk readsFormattingComments and documentationTeam collaboration

Libraries

LibrariesNextFTCFTCLibSolversLibPedro PathingRoad RunnerFTC DashboardMercurial v2Mercurial v1PanelsSloth

Community software

Community softwareBlaze FTCOpenLoopHive Vision

Sensors and vision

Vision overviewVision basicsLimelight 3A
EasyOpenCV basics
OpenCV pipelines
VisionBench
Starter Guide
Engineering
Design
Portfolio
Appearance
EasyOpenCV

VisionBench

Test an EasyOpenCV pipeline on your computer before using the robot

Overview

VisionBench is the current name of EOCV-Sim. It runs vision code on your computer using a saved image, video, or webcam as the input. This lets you inspect and tune a pipeline without repeatedly installing code.

A test loop: choose an image, run the pipeline in VisionBench, inspect its output, change one setting, and test again.

It simulates the vision parts of the SDK; it is not a full robot . You still need to test camera exposure, lighting, speed, and robot behavior on the real robot.

Installation

  1. Follow the official VisionBench download instructions. The current release requires 25 or newer. Check with java -version before launching it.
  2. Download the file for your operating system from the linked release page.
  3. Launch the downloaded JAR. If double-clicking does nothing, open a terminal in the download folder and run java -jar followed by the actual filename you downloaded.

The Java version needed to run VisionBench on your computer is separate from the Java and Android Gradle settings used to build your FTC app.

Pipeline example

For a first test, use a saved photo of a field object. Create a Java workspace through Workspace → External → Create Gradle Workspace. Open that folder in VS Code or IntelliJ, then add PassThroughPipeline.java under src/main/java:

import org.opencv.core.Mat;
import org.openftc.easyopencv.OpenCvPipeline;

public class PassThroughPipeline extends OpenCvPipeline {
    @Override
    public Mat processFrame(Mat input) {
        return input;
    }
}

processFrame receives one image frame. Returning input shows the frame without changing it. Once this works, try the one-color pipeline lesson.

The official workspace guide shows the current menu and file locations. If the pipeline does not appear, read the build error in VisionBench and check that the Java filename matches the class name.

Testing

  1. Choose an image source and open your test photo.
  2. Select PassThroughPipeline in the pipeline list. The preview should show the same photo.
  3. Change one part of the pipeline, save the file, and compare the new preview with the original.
  4. When you add thresholds, expose supported public, non-final Java fields to adjust them in the variable tuner. Record the values you choose in your code.

Use several photos, including different lighting and object positions. A color range that works on one image may fail on another.

Robot pipeline import

VisionBench can load a folder of pipeline classes from an Android Studio project, but those classes should not depend on or other unsupported robot hardware APIs. Follow its Android Studio workspace guide to select only the vision package.

Java workspaces are the simplest supported route. The pipeline guide says Kotlin and other JVM languages require building VisionBench from source, so do not expect a .kt file placed in a Java workspace to appear automatically.

Next steps

After the computer test works, move the pipeline into your FTC project, connect it to EasyOpenCV on the robot, and test with the robot's camera. Keep your first robot test slow and simple.

Sources

  • VisionBench repository and releases
  • VisionBench documentation
  • VisionBench download instructions
  • VisionBench: Workspace guide
  • VisionBench: Variable tuner
  • VisionBench: Android Studio workspace guide
  • VisionBench: Pipeline guide

OpenCV pipelines

Build a small color mask step by step with EasyOpenCV

VisionPortal

Open an FTC camera, attach a processor, and check the preview

On this page

OverviewInstallationPipeline exampleTestingRobot pipeline importNext stepsSources