• DepthAI-v2
  • How to get lower resolution images from the color camera?

I tried use setVideoSize and use its video output. But the images are cropped, not resized.

Thanks,

Dong

  • erik replied to this.

    Hello Dong_Liu , if the video size doesn't match the original (sensor) FOV, the stream will get cropped as well. One option would be to use camRgb.setIspScale(1,2) to downscale the isp, which will downscale the video output as well. More info about SetIspScale can be found here. Other options are mentioned in How to maximize FOV.
    Thanks, Erik

    BTW, is there any sample code to get the camera calibration after the image got scaled or copped?

    Thanks!

    • erik replied to this.

      Find out if you want to preserve the FOV in 720p resolution, use camRgb.setIspScale(2,3), in 360p resolution, use camRgb.setIspScale(1,3)

      Thanks!

      Hi erik,

      If I call camRgb.setVideoSize(640, 360) and camRgb.setIspScale(1,3), the images I get from camRgb.video are 1/3 scale of the 1080 resolution. Is the intrinsics of the (640, 460) just 1/3* intrinsics of (1920,1080)? Are distortion matrix also scaled?

      Thanks!

        Just asked our calibration expert to answer this question🙂

        Dong_Liu Distortion parameters doesn't need scaling.
        And as of intrinsic you need to multiply 1/3 in a scale matrix which is already done internally in the function linked here. you need to pass the resolution of the video you are fetching to the function linked above. Does that help ?