popcornmix / omxplayer

omxplayer
GNU General Public License v2.0
1.02k stars 334 forks source link

problem playing multiple multicast streams #652

Open jc13git opened 6 years ago

jc13git commented 6 years ago

I am trying to play multiple multicast streams (from Hikvision cameras) using SCREEN to start multiple instances of omxplayer. I referred to this link as a reference, and this works well when viewing a unicast source. An example of the command being used to launch omxplayer is below - one for each RTSP source IP.

/bin/bash /usr/bin/omxplayer --avdict rtsp_transport:udp_multicast --win 0 40 640 520 rtsp://user:password@192.168.1.10:554/Streaming/Channels/102/?transportmode=multicast --layer 1 --live

/bin/bash /usr/bin/omxplayer --avdict rtsp_transport:udp_multicast --win 640 40 1280 520 rtsp://user:password@192.168.1.11:554/Streaming/Channels/102/?transportmode=multicast --layer 1 --live

The first stream plays fine, but I get varying results when launching multiple instances. Network captures show that the separate multicast joins are successful and the video streams from each of the sources is arriving, but omxplayer will usually display the same video in the second instance. Depending on how many instances I launch, sometimes I will see different video feeds, but there are always duplicates.

I've tested (on a laptop) with multiple instances of VLC and I do not see the same behavior - i.e. the proper video is seen in each window. Not sure if this is a side effect from the way I'm launching multiple instances of omxplayer or if this could be a bug, so I though I'd at least log it here.

jc13git commented 6 years ago

After some more research, I believe that the root of this issue is ffmpeg related.

https://trac.ffmpeg.org/ticket/5156#no1