Connect matlab to ip camera

Viewed 97

Similar problem like Access IP-camera with matlab

I tried to read in two different IP Cams (Ubiquiti UniFi UVC G3 and a virtual camera via OBS Studio) independently.

It works with the VLC player, but not with Matlab. Unfortunately the matlab help could not help me either. I get the error: Cannot connect to the IP Camera Stream URL. Make sure the URL is correct and authentication is provided if needed.

I entered the URL from the interface (stand alone mode) of the camera or from the OBS-Studio into VLC and in VLC the video is displayed. I also checked the codec information from the VLC. Compared to the matlab help I have 2 streams, but the video stream is H264 (see picture1) (see picture2).

Code for connecting to virtual camera:

cam=ipcam('rtsp://localhost:554/live')

Code for connecting to UniFi camera:

cam=ipcam('rtsp://xxx.xxx.xxx.xxx:xxx/s0','user','pw'

What am I doing wrong?

Thanks for your help!

0 Answers
Related