Question: How to minimise input delay from a "local network stream" media source

RicRoller

New Member
I'm trying out receiving a network stream from a remote camera via a local wired Gigabit Ethernet network as an alternative to using HDMI extenders and a capture device... Running OBS 29.1.1 under Win11 Pro 22H2 on a Lenovo E580 laptop (i5-8250U / UHD 620 graphics), 24GB RAM, 500GB SSD).

The video source is an old Panasonic full-HD camcorder (its HDMI output provides 1920x1080 @ 50i) connected to a UrayTech UHE265-1S streamer; the stream output is 1920x1080 @ 25p, H264 coding, video bit rate 4Mbit/sec CBR, audio AAC, 48kHz, bit rate 128kbit/sec.

I have no issues with creating the "Media source" (either to receive an RTSP or an MPEG-TS (HTTP) stream); the source opens just fine and the video is displayed in the preview and audio is heard. But by default there's quite a noticeable delay (nearly 2 seconds) between what's being output from the camera and when it appears in the OBS preview.

The UrayTech streamer and the network are capable of much better; if I receive the stream using the command-line 'FFPLAY' tool, after adding some common "go faster" FFMPEG options I see a delay from camera to PC screen of just under 0.5 seconds.

For reference - FFPLAY command (to receive an MPEG-TS stream) I used (in Windows 11 command prompt (CMD)):
ffplay -flags low_delay -fflags nobuffer -probesize 500000 -f mpegts -i http://192.168.1.168/0.ts

I put those same "go faster" FFMPEG options into the definition of my media source in OBS, specifying the format explicitly as mpegts and adding the FFMPEG options in tne necessary 'option=value' form:
flags=low_delay fflags=nobuffer probesize=500000
I also tried reducing the amount of network buffering from 2MB (default) to 1MB

Delay from camera to OBS preview display was much improved, down to just under 1 second, IMO reasonable (and probably acceptable for my intended application), but still not quite as good as seen with FFPLAY.


So I'm wondering if there are any further settings I can tweak to reduce the delay even further and get closer to what I see with FFPLAY?

Thanks :-)
 
Top