Question / Help I get a laggy stream with a dedicated pc running on a 3900x

Pareidolia4k

New Member
I have a dual setup with ndi with a gigabyte connection between both pc's. ( I tested it yesterday) I bought 3900x to replace my 6700k and for some reason it's just not that great. it's a bit laggy and not all that great to begin with. It's miles ahead from my 6700k but it's not quite there yet has it seems that some games, for instance, Snowrunners, runs better on Nvenc with my 980ti. I don't know if it's because i'm bottlenecking with my ram being 2 sticks of 8 gigs each at 2133 but something is definetly going on. I usually stream at 1080p on twitch at 8000k with my partenered account. Now since i'm testing it on an alt, I downed it to 6000 just to make sure even tho I tried both but it doesnt make a difference lag wise. I might got used to higher refresh rate i'm not sure. It doesn't feel like a 60fps would on my gaming pc.

I stream on medium, my cpu usage is litterally 25%

Here are my logs!

also, here's a sample of my stream > https://www.twitch.tv/videos/621557731
> https://www.twitch.tv/videos/621562813

I don't know if i'm just to picky with the stream quality but I was expecting better. I was at least expecting not to have to do 900p when there's no folliage or a lot of grass around/ moving trees like in the Witcher 3 or something.

Maybe it's because I don't know what to put in the x264 options? That might help? It seems not alot of people are making videos about this very line wich seems important for a boost in quality. I tried Eposvox's ''secret sauce'' but no dice for me. It didn't work very good.

Thank's for your time and have a good one :)
 

Attachments

  • 2020-05-15 10-32-25.txt
    12.1 KB · Views: 40
Last edited:

carlmmii

Active Member
There's no recording/stream attempt in those logs, so no metrics/settings are shown. Make sure to record/stream for at least 30 seconds, stop, and with OBS still open, select "upload current log file".
 

carlmmii

Active Member
Aside from a few of the slow preset tests, your encodes are perfect as far as your stream-computer side goes. No rendering lag, and only getting encoding lag for a bit when using the slow preset (which is expected -- my 3900x does the same).

Since you're using NDI, that brings into question quite a few things now. Are you using OBS on your gaming rig to send the NDI stream? If so, we need that log file as well (again, with recording/stream attempt).
 

carlmmii

Active Member
Aside from a few of the slow preset tests, your encodes are perfect as far as your stream-computer side goes. No rendering lag, and only getting encoding lag for a bit when using the slow preset (which is expected -- my 3900x does the same).

Since you're using NDI, that brings into question quite a few things now. Are you using OBS on your gaming rig to send the NDI stream? If so, we need that log file as well (again, with recording/stream attempt).
 

Pareidolia4k

New Member
Aside from a few of the slow preset tests, your encodes are perfect as far as your stream-computer side goes. No rendering lag, and only getting encoding lag for a bit when using the slow preset (which is expected -- my 3900x does the same).

Since you're using NDI, that brings into question quite a few things now. Are you using OBS on your gaming rig to send the NDI stream? If so, we need that log file as well (again, with recording/stream attempt).


This is from my streaming pc,

Streaming Pc > https://obsproject.com/logs/UJxR2QgYUVIBI9kY



Since i'm not recording/streaming on my gaming pc i'm unsure how to show you my logs. you want me to stream from this pc as well? If so, here they are!

Gaming Pc >https://obsproject.com/logs/QtFb7yYCyzboXcZi
 

carlmmii

Active Member
Just got a chance to watch your clips. I see nothing that really stands out as far as quality or stuttering. If you have a specific timestamp that you're wondering, that would help.

Some things to keep in mind. The twitch VOD player isn't 100% flawless (the live player for whatever reason has fewer issues). The VOD player has random hiccups on playback, which when you're using it to assess smoothness, makes it look like your video is stuttering. Also, even VLC can have problems with 100% smooth playback. The only way to truly confirm that you have no stuttering is to save a local recording using your stream encoder (in recording, use the "same as stream" option), and verify in a video editor that there are no duplicate frames.

Also, you're running your monitors at 144hz. This means that the down conversion to 60fps is not going to be exact -- you will be discarding either 1 or 2 frames for every frame of output. Dropping your monitors to 120hz will prevent this.

As far as any kind of rendering lag, neither your gaming rig or your streaming rig are encountering anything noteworthy, as should be the case running as administrator. So if there are any issues with actual stuttering occurring, it is most likely a result of video playback, or there's something happening with the NDI frame transfer between systems.

As far as the picture quality, it looks great. Exactly as expected for the settings you have. You can critique it all you want, and there are plenty here that will have their own opinions of what settings work best. The important thing is that you aren't losing any frames to encoding lag.
 

Pareidolia4k

New Member
Just got a chance to watch your clips. I see nothing that really stands out as far as quality or stuttering. If you have a specific timestamp that you're wondering, that would help.

Some things to keep in mind. The twitch VOD player isn't 100% flawless (the live player for whatever reason has fewer issues). The VOD player has random hiccups on playback, which when you're using it to assess smoothness, makes it look like your video is stuttering. Also, even VLC can have problems with 100% smooth playback. The only way to truly confirm that you have no stuttering is to save a local recording using your stream encoder (in recording, use the "same as stream" option), and verify in a video editor that there are no duplicate frames.

Also, you're running your monitors at 144hz. This means that the down conversion to 60fps is not going to be exact -- you will be discarding either 1 or 2 frames for every frame of output. Dropping your monitors to 120hz will prevent this.

As far as any kind of rendering lag, neither your gaming rig or your streaming rig are encountering anything noteworthy, as should be the case running as administrator. So if there are any issues with actual stuttering occurring, it is most likely a result of video playback, or there's something happening with the NDI frame transfer between systems.

As far as the picture quality, it looks great. Exactly as expected for the settings you have. You can critique it all you want, and there are plenty here that will have their own opinions of what settings work best. The important thing is that you aren't losing any frames to encoding lag.

What you said about 120hz vs 144hz is quite interessting i'll make sure to check that. What about the x264 options (separated by space) commands?! is there a way to make it look even better by using that? If so, is there a guide somewhere because I've looked and haven't found anything useful.

Thank you very much for your time! Have a good one ;)
 

BigYuckFou

Member
It has taken me 9 months of testing to get to those settings, and they are specific to each PC/iuse case. I will be happy to assist if you find yourself in need.
 

BigYuckFou

Member
if you plan to discuss this with me please do so under this thread located here: https://obsproject.com/forum/thread...fection-suggestions.121717/page-2#post-458408

I duplicated my post there as well. so it can be tracked there.


It has taken me 9 months of testing to get to those settings, and they are specific to each PC/iuse case. I will be happy to assist if you find yourself in need.

I can give you a few pointers. The goal I had was squeezing 1080p@60fps fast motion content into 6000kbps so it looked good as possible. I can tell you no matter how much CPU you have at some point you play a balancing game between encoder lag/dropped render frames and quality.

Here are the settings that matter most on fast motion content. I will explain my understanding of each. and their encoder speed impact. when testing these if you start your stream and get immediate dropped encoder or render frames you set them too high. and you need to back them off as even if it stops immediately after initial drop during your stream you WILL get encoder overload.

My current x264 options separated by spaces.
threads=21
b_adapt=1
direct-pred=temporal
me=tesa
trellis=2
bframes=16
ref=1
subme=5
analyse=all
rc-lookahead=120
me_range=16
aq-mode=3
partitions=all

Explanation:

threads=21

(1-32) you can go higher, but don't... get this as low as possible. preferably equal to the number of real CPU cores you have for best quality. If you raise the other settings below and start to get encoder dropped frames raising this can thwart that in some cases.

b_adapt=1
(values are 1 or 2) two being newer and significantly slower. two is not necessary. yet preferred. if you use bframes greater than two, the speed decrease significantly and I mean SIGNIFICANTLY. so I leave it at 1. I prefer more brames at 16 for better bitrate compression and overall quality gains. badapt two and brames >3 will give your CPU a heart attack.

direct-pred=temporal
(spatial or temporal) spatial is perfectly fine. temporal is better looking and searches a more complex pattern for motion vectors

temporal has a quite significant speed impact dependent on other settings. leave this at spatial, get the other settings as high as possible and if temporal then works use it.. otherwise use spatial. the quality gain using temporal is almost insignificant.

me=tesa
(dia, hex, umh, esa, tesa) do not use dia or esa. if you are going to use esa you might as well use tesa. this setting is the most impact in my opinion of fast moving content. tesa is the best you can get, and dropping to umh has a significant impact on quality during fast motion. so set this to tesa and then raise everything else after.

trellis=2
(0, 1, or 2) zero is off, one is ok, and 2 is superb. speed impact is little. it helps to use 2 so that you get better bitrate usage about 5-10% savings overall on the video as a whole. so you get better quality out of less bitrate, say the 6000 preferred.

bframes=16
(0-50) but you can go higher. these help with video quality. do not go too high as playback issues for viewers may arise. 16 is great. you can test up to around 30 IMO. you will read they have a significant impact on bitrate usage. but the quality gain is immense. B frames look great. IMO using 6000kbps you have plenty of headroom for bframes. use them!

ref=1
Reference frames are tough. they take A LOT of cpu to process. I use 1, as I have found they are simply not necessary in my use case. (fast motion looking good). obviously for recording you want higher, and higher is better. but the speed impact going from 1 to 2 is HUGE. especially using me=tesa from above. leave this at 1. if you get the other settings where you want them and can raise it, do it.. but your CPU will have a heart attack as will dropped encoder frames. this one settings is why most people cannot encode using the slow preset but can do medium. hell most people can use placebo as long as they make ref=1...

subme=5
(0-11) you wont read about 11 anywhere. 10 is insane. 8-9 is preferred but very CPU intensive/ 6-7 is superb. 5 is premium and a great overall look. 4 is perfectly fine. I started with 4. perfected everything then moved to 5 in the end. but again. 4 looks wonderful! and the speed at 4 is superb. moving to 5 has a significant speed impact and may cause dropped frames.

analyse=all
This setting seems to smooth the content overall. I have found very little information about this setting. if you find something let me know. I leave it on "all" but you can remove this one if you feel the need.

rc-lookahead=120
(0-240) if you stream at 60fps, then 120 lookahead is two seconds worth of forward seeking for frame type determination. 120 @60fps is IMO preferred. 240 is outrageous. 60 is sufficient in most cases. speed impact is negligible, but quality is affected at lower than FPS out numbers.

me_range=16

(0-???) this has a significant impact on speed but is the depth of motion vector search when using me>= umh, esa, or tesa. this is locked at 16 using hex and cannot be raised higher. significant impact on fast motion smoothness. I use 16. 24 is top dog, but SIGNIFICANTLY slower.

aq-mode=3
(0, 1, 2, or 3) 3 is preferred. and is what you should use for visual perception quality.

  • 0: Do not use AQ at all.
  • 1: Allow AQ to redistribute bits within each frame.
  • 2: Allow AQ to redistribute bits across the whole video.
  • 3: Auto-variance AQ with bias to dark scenes.

partitions=all
allows the usage of all partition sizes of macroblocks. all is best, or default setting of slow-placebo will also work just fine. slightly less fast and slightly better quality, just a tad.. and I mean a tad.

resources:
 

BigYuckFou

Member
FYI, I am placing more information in this thread to enhance what I posted above and going to provide a starting point to test and raise from:

 
Top