I am trying to stream the video from the BlueROV2 into Matlab. Is there an ip the camera stream is fed into that I can use, or is there a way to easily stream it to an ip? I’m not sure if I can tap into the stream that’s in qgroundcontrol. I recently also found out about gstreamer. I’m not sure if I can use that to stream the video into Matlab. I’ve been looking into PsychToolbox 3 add-on in Matlab to use with gstreamer, but a simple IP stream would be much more simple it seems. I’ve also been looking into the companion software, and it looks like there should be a stream going somewhere, but every URL I’ve tried hasn’t worked. I’ve been looking at this post on the forums but can’t seem to figure it out. I got it working in VLC media player, and I’m currently attempting to integrate my Matlab scripts into that. Basically, I’m not sure which direction to take this, or which would be easiest. If anyone has any advice or tips, I would really appreciate it. Thank you!
Currently our video is implemented by a simple UDP stream of a raw (as in not-encapsulated) H264 stream. This h264 stream is sent to the topside computer at IP 192.168.2.1 and port 5600.
Is this what you mean by “stream it to an ip”? I believe that relies on loading a RTSP stream, which we currently do not provide.
With that gstreamer pipeline running, the H.264 stream coming in over UDP is decoded to raw video and is then available to other programs by opening the /dev/video8 video device.
If Matlab can use a local webcam, this might work.
If you’re on Windows I don’t know how to do it.
I am using a Blue Robotics USB cam streaming from a Raspberry Pi as the UDP video source on port 5600.
EDIT: the latency is pretty bad using vaapidecodebin in my pipeline.
It’s much better using avdec_h264, but requires a lot more CPU for the reciever/translator.
I don’t know enough about gstreamer to optimize the pipeline for this setup. It might be you don’t need to process things as much in between the udpsrc and the v4l2sink.
Thank you for the reply. Currently the laptop we are using is a pretty beefy gaming laptop running windows 10, but I should be able to install Ubuntu on it as long as my employer doesn’t care. I’m going to give this a try tomorrow or some other time this week. Thank you!
If you need some help to understand how to create gstreamer pipelines and debug it, you should check this post that explains a workflow that may help you.