How to broadcast a video stream in a local network in real time?

I am trying to create a system capable of broadcasting a computer screen capture to several other PCs on a local network.

So far, I have managed to install nginx on a Raspberry Pi with the rtmp module, and I can use Raspberry as an RTMP server through OBS. I use VLC to view the stream.

Here is the problem. The main broadcast computer will display a timer that counts and potentially transmits channels, so it would be ideal to keep broadcast latency to a minimum (in real time?). I currently have a 4-6 second delay between what is happening on the screen and the stream, and I'm looking for ways to further reduce it.

  • Is there a way to determine how much of this delay time is related to encoding and how much of it is related to transmission?
  • I am currently doing a 1080p30 search and have tried settings such as zooming out and minimizing the impact of the network, but to no avail.
  • I read other topics regarding LAN broadcasting in this forum, and someone mentioned that RTMP was not a good approach ... If so, what would be the best approach?
  • Any suggestions are welcome and appreciated. I'm more interested in free solutions, since I don't have a budget, and I do it for free for someone else.
  • I also looked at VLC streams, but I don’t want to show the whole screen of the computer, as there will be controls that viewers should not see. And the only thing that VLC can do is to indicate which part of the screen to broadcast, which does not seem like a great solution. I chose OBS because it is the only free broadcast software that can give me a specific window.

Thanks in advance:)

+8
video-streaming lan real-time rtmp vlc
source share
2 answers

At first I think that you are right to use OBS, this is a great project that allows you to capture a lot of things.

If you want to optimize the video speed, you can try several ways:

  • The first one is using another RTMP client, VLC is good, but it uses too much cache, try this one (just set the correct rtmp url, clear the input and connection of NetGroup)
  • Then you can try another server, I wrote the following tutorial on How to set up your own RTMFP server using MonaServer ,
  • And finally, you can change your OBS settings (I use Twitch settings that are optimized for real time).

For me with OBS + MonaServer + my VideoPlayer, I have a delay of 2 seconds, and not in real time, but this is already better.

The last thing that OBS is known to add latency in RTMP sessions, I know that it can be improved by changing the source code of OBS, but here it is a bit complicated ...

Hope this helps! Contact me if you need more information.

+8
source share

You need to compress and unzip. You use all the bandwidth to connect Gigabit Ethernet. If your total distance is less than 15 feet, any HDMI cable will work. For distances greater than 15 feet, make sure you get a certified cable (some can work up to 45 feet without signal). VGA will work over long distances, like DVI.

OR, you can drop to 720P and leave enough bandwidth to complete the task.

+2
source share

All Articles