Question / Help RTSP TCP stream via Media Source

cbobach

New Member
I have multiple RTPS streams rtsp://ip:port/path that uses tcp, which I want to cut between. I am trying to add them via the media source.

The log gives the following:
Code:
12:11:31 AM.773: User added source 'cam b' (ffmpeg_source) to scene 'Scene B'
12:11:52 AM.268: [Media Source 'cam b']: settings:
12:11:52 AM.268:     input:                   rtsp://xxx.xxx.xxx.xxx:yyyy/zzzzzz
12:11:52 AM.268:     input_format:           
12:11:52 AM.268:     speed:                   100
12:11:52 AM.268:     is_looping:              no
12:11:52 AM.268:     is_hw_decoding:          no
12:11:52 AM.268:     is_clear_on_media_end:   yes
12:11:52 AM.268:     restart_on_activate:     yes
12:11:52 AM.268:     close_when_inactive:     yes

No visible error.

- It works running ffplay -rtsp_transport tcp rtsp://ip:port/path
- It works running ffmpeg -rtsp_transport tcp -i rtsp://ip:port/path ./cam.avi -y
- It works in VLC if configured to use TCP.
- It works using the VLC Video Source, but it seems to drop connections when having multiple sources.

I am on Ubuntu 19.04, OBS 23.2.0 compiled from source.

Are there anyway that I can specify OBS to use TCP and not UDP for RTSP streams?
 

Tuna

Member
If its an option you can try the GStreamer plugin found on this page. That should work with RTSP streams just fine. It may just a little bit more difficult to set up than the media source or VLC source. For that plugin you can use RTSP transmission over TCP if you change the URI protocol to "rtspt://".
 
Top