Question / Help RTSP Media Source dropping out.

uc_1

New Member
Hi All,

New to OBS, and using version 25.0.1.

I am trying to stream a camera feed to youtube which is generally working, but I'm having annoying issues.

Feeding to: https://www.youtube.com/watch?v=ShKB3VZoKjQ

About 2 or 3 times a day, the feed will die. I'm not sure why, but we have bad internet here so it's likely the connection between OBS and Youtube drops out, or the link between the NVR and the OBS computer is dropped (although that seems unlikely as hey are on the same gigabit network switch). Sometimes it will go a whole day without dropping out, but usually I'm restarting it 2-3 times a day. I have to go into the Media Source properties and press OK to get the feed back. Sometimes I also have to stop and restart streaming but most commonly just refreshing the media source works. I've tried using the feed from the camera direct and also from my NVR. Both exhibit the same behaviour. Although we have bad internet, the internal network has no issues that I am aware of. The machine that OBS is on is connected by Ethernet to the same switch as the NVR and is always on.

The Media source is set as follows:
Local File is unticked
Restart Playback when source becomes active (tried ticked and unticked)
Network Buffering: 2MB
Input: rtsp://xxxx:xxxx@192.168.0.55:554/Streaming/Channels/1501/ (obviously I've blanked username/password)
Input Format: Blank
Use Hardware decoding when available: Ticked
Show nothing when playback ends: Ticked (I've tried both, but now I've put a text GDI behind the source saying "internet issues" which shows when the camera feed fails)
YUV Color Range: Auto
Seekable: Unticked.

So, is there a workaround for this? I was thinking about adding a plugin to change scene for a second and switch back in a hopes that will resolve it, but that seems very messy. Any thoughts pleasE?
 

wseaton

New Member
Hi there - I use OBS to live stream from IP cameras in animal shelters to Youtube and have a near identical problem. Randomly, sometimes several times a day or sometimes days apart my input freezes. Log file shows nothing. IP cams also continue to record to a NVR without a hitch, so I've concluded the problem is with OBS and RTSP, and if you google around you'll see others with the same problem and no real solution other than clunky solutions like using VLC as an intermediary source. I beat my head against the wall for a year on this.

My solution was 'nuke from orbit' and more direct. I basically wrote a simple BAT file that kills the OBS session and then restarts it once an hour. Anybody viewing the youtube stream will see a black feed for a few seconds as OBS restarts, but so what. I don't have to baby sit it and the youtube session isn't affected. PM me if you want to see that batch file.
 

uc_1

New Member
Thanks for the reply Wseaton.

I've actually found a work around as well. I tried VLC but that seemed just as unreliable. In the end I went for a script and a plugin.

The script changes to a different scene when the media source ends (e.g the camera feed stops).
I then downloaded the Advanced Automatic Scene Switcher that will switch back to the main scene with the camera after 1 second. With the media source set to "Restart playback when source becomes active" it automatically restarts the camera feed.

Thus far it seems to be working well! Touch wood :)
 

wseaton

New Member
Haha...that works to. I really wish the developers would just fix the RTSP issue. If the problem is with the camera feed then explain why the recording is perfectly smooth :-)
 
Top