FFC Camera Visualization

This example shows how to use the Camera component to display the camera feed from the FFC camera.

For FFC, the camera board socket must be specified. In our case the cameras are connected to socket A, B and C. After setting the resolution to 1200p and downscaling using ISP to 800p, the camera feed is displayed in a window.

Note

Visualization in current example is done with blocking behavor. This means that the program will halt at oak.start() until the window is closed. This is done to keep the example simple. For more advanced usage, see Blocking behavior section.

Setup

Please run the install script to download all required dependencies. Please note that this script must be ran from git context, so you have to download the depthai repository first and then run the script

git clone https://github.com/luxonis/depthai.git
cd depthai/
python3 install_requirements.py

For additional information, please follow our installation guide.

Pipeline

Pipeline graph

Source Code

Also available on GitHub

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
from depthai_sdk import OakCamera

with OakCamera() as oak:
    cama = oak.create_camera('cama,c', resolution='1200p')
    cama.config_color_camera(isp_scale=(2,3))
    camb = oak.create_camera('camb,c', resolution='1200p')
    camb.config_color_camera(isp_scale=(2,3))
    camc = oak.create_camera('camc,c', resolution='1200p')
    camc.config_color_camera(isp_scale=(2,3))

    stereo = oak.create_stereo(left=camb, right=camc)
    stereo.config_undistortion(M2_offset=0)

    oak.visualize([stereo, camc, cama, stereo.out.rectified_left], fps=True)

    oak.start(blocking=True)

Got questions?

Head over to Discussion Forum for technical support or any other questions you might have.