Forums - Open 4 cameras at the same time

7 posts / 0 new
Last post
Open 4 cameras at the same time
boyuchen
Join Date: 3 Jul 19
Posts: 2
Posted: Wed, 2021-05-12 18:01

Hi,

My current project is on the Robotics RB5 platform, which uses multiple cameras for object detection. I have tested that the Main camera, Tracking camera and GMSL camera can be opened separately, but how do I open them at the same time? , I have used gst_gui app to open it under different terminals, but it still fails. Is there any way to open multiple cameras at the same time?

thans.

boyu

  • Up0
  • Down0
kevin.dai
Join Date: 21 Oct 20
Posts: 137
Posted: Fri, 2021-05-14 12:49

Let me check if there is such sample app.

When I get result, I will let you know

Thanks

  • Up0
  • Down0
kevin.dai
Join Date: 21 Oct 20
Posts: 137
Posted: Wed, 2021-05-19 15:20

Hi boyu,

I got response from camera engineers, here is comments from them:


RB5 only has two IFEs, usually only two cameras can be opened at the same time.
But RB5 also has additional ife_lite, they can get the raw data of other cameras.
 

Thanks.

  • Up0
  • Down0
boyuchen
Join Date: 3 Jul 19
Posts: 2
Posted: Sun, 2021-05-23 03:10

Dear kevin.dai,

Thanks for your reply, but how can i use additional ife_lite, when i open two camera at the same time?

Can you have sample code to use additional ife_lite?

thanks.

Boyu

 

  • Up0
  • Down0
kevin.dai
Join Date: 21 Oct 20
Posts: 137
Posted: Wed, 2021-05-26 14:00

Let me check if we have sample code for addination IFE.

I will give you update soon.

  • Up0
  • Down0
mita.rathod
Join Date: 17 Sep 18
Posts: 59
Posted: Wed, 2021-06-02 16:18

Hi Customer,
When you open the third camera, if the app only requests raw data, the camera will work on ife lite.
Hope this helps!

  • Up0
  • Down0
jhwill
Join Date: 30 Apr 21
Posts: 12
Posted: Wed, 2021-06-30 17:59

I've been able to open multiple cameras at the same time with a command like the one below It will open the IMX577 (main camera) and the OV9282 (tracking camera), and compose their frames next to each-other in an output video. Currently the performance is quite bad. I'm not 100% sure on the bottleneck yet. Also, the frames are out of sync.

gst-launch-1.0 \
    --verbose \
    --eos-on-shutdown \
    qtiqmmfsrc camera=0 name=imx577 \
        ! video/x-raw,width=640,height=400,framerate=15/1 \
	! videoconvert \
	! compositor.sink_0 \
    qtiqmmfsrc camera=1 name=ov9282 \
        ! video/x-raw,width=640,height=400,framerate=15/1 \
	! videoconvert \
	! compositor.sink_1 \
    compositor background=1 name=compositor sink_0::xpos=0 sink_0::ypos=0 sink_1::xpos=640 sink_1::ypos=0 \
        ! 'video/x-raw,width=1280,height=400,framerate=15/1' \
        ! videoconvert \
        ! x264enc \
        ! h264parse \
        ! mp4mux \
        ! queue \
        ! filesink location=/root/capture.mp4

Another (possibly more performant) option would be to spit the frames out as JPG files instead of trying to use the `omxh256enc` (which seems to have some problem.)

gst-launch-1.0 \
    --verbose \
    --eos-on-shutdown \
    qtiqmmfsrc camera=0 name=imx577 \
        ! video/x-raw,width=1280,height=800,framerate=60/1 \
	! videoconvert \
	! compositor.sink_0 \
    qtiqmmfsrc camera=1 name=ov9282 \
        ! video/x-raw,width=1280,height=800,framerate=60/1 \
	! videoconvert \
	! compositor.sink_1 \
    compositor background=1 name=compositor sink_0::xpos=0 sink_0::ypos=0 sink_1::xpos=1280 sink_1::ypos=0 \
        ! 'video/x-raw,width=2560,height=800,framerate=60/1' \
        ! videoconvert \
        ! jpegenc \
        ! queue \
        ! multifilesink location=/root/capture%05d.jpg

Another option would be to each camera to a different output file, and seam them together at a later time. The command below is more like the one in the RB5 documentation for video decoding.

gst-launch-1.0 \
    --verbose \
    --eos-on-shutdown \
    qtiqmmfsrc camera=0 name=imx577 \
        ! video/x-h264,width=1280,height=800,framerate=60/1 \
        ! h264parse \
        ! mp4mux \
        ! queue \
        ! filesink location=/root/imx577.mp4 \
    qtiqmmfsrc camera=1 name=ov9282 \
        ! video/x-h264,width=1280,height=800,framerate=60/1 \
        ! h264parse \
        ! mp4mux \
        ! queue \
        ! filesink location=/root/ov9282.mp4
  • Up0
  • Down0
or Register

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.