Question / Help More delay better quality ?

Jack0r

The Helping Squad
Think about encoding like a packing system. Every second 30 packets enter the "encoder" and want to be compressed, so in the next second the next 30 packets can be compressed. Now if you use delay, we add a "buffer" to this. This is a little save space which saves your packages for a certain amount of time. it makes pairs of each 30 packets and them sends them when the delay is reached.
Now comes the problem, the delay doesnt change anything about the speed/time the encoder has/wants to work on those 30frames. The encoder just starts encoding them later. He still only has one second to do so, just like without any delay.
You are literally asking for a time machine ;) it would give the encoder more time to encode to reach a higher quality, but would add more and more delay each frame. For real time streaming this would look horrible for your viewer.
If you encode a movie on your system locally, this technique is used. It doesnt matter how long the encoding takes as you will watch the Movie only after its finished. Thats why you can sometimes use 8hours of encoding time for a 2 hour movie.
For livestreaming this method wont work!
 

Gol D. Ace

Member
My concern was more using a higher Bitrate then your Connection can handle.

I tought of a Concept like buffering one min with a higher bitrate and then sending it out.

I have a spare root Server but not that great uploadrate at home so I got a bit creative.

I don't know if this is possible with a server but it would be somehow awesome for People with lower Upload speeds.
 

hilalpro

Member
OBS would just drop frames in that case.. although a higher buffer length on the player side can help compensating for the delays/pauses caused by the minor bitrate spikes the protocol it self it not suited for this.
 

Jack0r

The Helping Squad
He is actually asking for this:
iyA4iXAO1ZWpJ.jpg

As you can see, IF this would be possible, you would just give your viewers a bad bad stream. The time with no information and thus a black/not moving picture will get bigger each second.
 

R1CH

Forum Admin
Developer
I have no idea why you think that is what he wants. In terms of delay-quality tradeoff, rc-lookahead is probably the big factor there. Unfortunately it comes at a non-zero CPU cost.
 

Gol D. Ace

Member
My Idea was to stream to my server which buffers the stream with a higher bitrate and then sends it out to twitch but this doesn't seem to be possible...
 

FerretBomb

Active Member
He seems to want to have a buffer zone to allow packing more information into each packet (like better zip compression) more optimally.
As noted, that doesn't work in a livestreaming setting all that well, due to the constant flow of data.

If you DO have spare CPU cycles laying around, you can try dropping from Veryfast to the Faster or Fast preset. It'll give a (slightly) better image quality, and optimize the encoding portion so you get more visual quality for less bitrate. But again, it's only a slight fidelity improvement for a pretty noticeable CPU load increase.

(edit) Also, some people DO use a local RTMP server and re-encode it... I haven't looked at doing so myself, but as I understand it they send a MASSIVE bitrate (very little encoding) across their LAN, and the RTMP server re-encodes it at a lower bitrate with higher quality settings before sending it out over the WAN link to Twitch (or whichever service you use). At least that's the idea.
I haven't looked into it again, but would recommend the Search function and jumping in on those threads/asking the people already working on it as to their success/problems.
 

Jack0r

The Helping Squad
Gol D. Ace said:
My concern was more using a higher Bitrate then your Connection can handle.
I tought of a Concept like buffering one min with a higher bitrate and then sending it out.
I have a spare root Server but not that great uploadrate at home so I got a bit creative.
I don't know if this is possible with a server but it would be somehow awesome for People with lower Upload speeds.

I just wanted to give a explanation why the (bold marked) ideas wouldnt be helping in a livestream environment. If I missunderstood his idea, sorry.

So, if cpu usage has some room, but going to a "slower" preset is no option, increasing the rc-lookahead alone could help the quality? Or what do you mean by delay-quality tradeoff R1CH?
 
Top