Question / Help Best Stream Quality 720p?

Hello,

I have a question. I want to find the BEST Stream Quality for viewers in my OBS. The resolution should be 720p with 60fps.
Even tho, I have a realy good Internet connection and a realy good computer.

Specc:

CPU:i7-3770k @ 4,6ghz 1,292 Voltage Overclocked
MOTHERBOARD:ASROCK Z77 Extreme6
COOLER:H105 Liquidcooling + Noiseblocker BlackSilent PL2 2x
RAM:GSKILL 8GB 2400 CL8 Kit 8-10-10-24-2T
Hard Drive:128 GB OCZ Agility 3 SSD
NVIDIA DRIVER:340.52

I hope someone can give me good settings for it. Currently im using:

Resolution: 1280x720p
FPS: 60
Preset: fast
Bitrate (CBR): 3000
Encoding Profile: main
Audio: 128 Bitrate / Codec: AAC

It runs realy good but sometimes I notice that the screen will be pixel when i making fast moves. I also dont want to set the bitrate too high so viewers can't watch, because most of the viewers doesn't have a decent download rate. I also notice if someone has a monitor that uses 1920x1080, my 720p stream will be not look good as if you use a lower reso monitor. (e.g 1280x720p) The quality is much better because if im watching my own stream on my 1920x1080p monitor, the stream doesnt look good if i watch it on my laptop which supports only 1024x768. It looks very very good if i watch it on my laptop tho.

Maybe someone can give me some tips about it.
 

Sapiens

Forum Moderator
Your settings are fine. Some pixelation is normal given the bandwidth restrictions you're working with. Personally I prefer to use the aq-mode=2 custom param but it isn't going to work any miracles.
 

Boildown

Active Member
If you post a log file, we can judge the performance you're getting right now.

Usually with hyperthreaded quad cores, you get some benefit from restricting the number of threads that x264 generates, with the "threads=x" command, where x is a number less than 12 (12 is the default for your CPU). I find 9 or 10 threads usually results in the best performance.
 

Sapiens

Forum Moderator
Usually with hyperthreaded quad cores, you get some benefit from restricting the number of threads that x264 generates, with the "threads=x" command, where x is a number less than 12 (12 is the default for your CPU). I find 9 or 10 threads usually results in the best performance.
While you're of course free to run your stream with any settings you choose, for what it's worth I've never found this to be the case, and to my knowledge none of the OBS support staff have ever been able to replicate your results either. Unless the goal is to simply restrict the amount of CPU power used by the encoder (which should probably be done in other ways) or you're an edge case running a system with so many cores that the encoder spawns enough threads to negatively impact quality, I don't think this is something worth casually recommending to users.
 
Last edited:

Boildown

Active Member
Sapiens and Submergelol:

In my testing, Intel quad cores with hyperthreading, like the desktop i7s, 2600k, 3770k, 4770k, etc, are already an "edge case" where too many threads are spawned by the encoder. Its a quad core CPU at heart, yet x264 generates 12 threads. x264 doesn't make any advanced calculations here, it just multiplies the virtual CPUs by 1.5 and uses that many threads. Hyperthreading is good, but not that good.

I've measured 9 or 10 threads to be ideal in actual testing on my i7 2600k. If I have other things running on the CPU, I generally go with 9, if I've dedicated the computer to encoding, I go with 10.

The alternative Sapiens implies is probably process priority. But this is a bad solution, because it doesn't solve the fundamental issue of too many threads, it just robs CPU power from other processes on the system (like the game) if set higher, or robs x264 if set lower.

Has the OBS staff tested this and found it to not work, or just not tested it? The statement about the OBS staff was ambiguous. In a quick search a few people have responded positively to this suggestion of mine in the past, notably LTRoyalShrimp, and a few others, but I'll concede that it could be confirmation bias.

I suppose I will have to come up with an experiment to "prove" this assertion.
 
Nice explanation, i think im going to set:

aq-mode=2
threads=9

for streaming. Should be okey if i understand all correct in here. Also it makes sense what you are telling @Boildown

But should i set the preset to fast anyways?
 
Ehm i figured out... i7-3770k only have 4 cores and 8 threads.. Why should I set it to 9 then? lol. Even the i7-2600k have only 4 cores and 8 threads.
 

Boildown

Active Member
There's value in setting more threads than cores, as all threads aren't necessarily active or using an entire core (even a virtual hyperthreaded half-core) at all times.

My testing clearly showed that performance was highest at 9 or 10 threads (within margin of error to tell between the two). Lower than 9, performance went down the lower the setting (7 was worse than 8, 6 was worse than 7), and more than 10, performance also went down (12 was worse than 11).

Rather than trust me, you can always experimentally find out the best number for yourself. My testing was with Planetside 2, perhaps WoW or LoL have different results, for example (though I doubt it). The only way to truly know is to try it and look at the duplicated frames in the log file, to see how they change (that's the way I measured performance). Just be sure to have "statistically valid" samples.... i.e. videos long enough to give consistent results. Even with the exact same input video I found that 1 minute test videos were too short, for example.
 
Last edited:

Sapiens

Forum Moderator
The alternative Sapiens implies is probably process priority.
...
Has the OBS staff tested this and found it to not work, or just not tested it?
...
I suppose I will have to come up with an experiment to "prove" this assertion.
Process priority can sometimes work for particular games (can't say any come to mind at the moment though) but it shouldn't be necessary most of the time. I'd much prefer people stick to changing their preset when necessary, or maybe tweaking a variable like subme if they know what they're doing. The edge cases I had in mind are for CPUs with more than 6 physical cores and hyperthreading, where you'd end up with something like 24+ threads spawned. A simple quad core with hyperthreading is not something I'd consider an edge case at all.

Yes, we've scratched our heads at your frequent suggestion to manually set the number of threads being spawned, and in testing we've found that at best it makes no difference and at worst results in poorer encoding performance. Like I said you're free to set things up however you'd like for your own stream but having people monkey with the number of threads x264 spawns as a general purpose tweak seems ill-advised.

Looking forward to seeing some reproducible numbers!
 
There's some value in setting more threads than cores, as all threads aren't necessarily active or using an entire core (even a virtual hyperthreaded half-core) at all times.

My testing clearly showed that performance was highest at 9 or 10 threads (within margin of error to tell between the two). Lower than 9, performance went down the lower the setting (7 was worse than 8, 6 was worse than 7), and more than 10, performance also went down (12 was worse than 11).

Rather than trust me, you can always experimentally find out the best number for yourself. My testing was with Planetside 2, perhaps WoW or LoL have different results, for example (though I doubt it). The only way to truly know is to try it and look at the duplicated frames in the log file, to see how they change (that's the way I measured performance). Just be sure to have "statistically valid" samples.... i.e. videos long enough to give consistent results. Even with the exact same input video I found that 1 minute test videos were too short, for example.


Hm yes, but my CPU only have 8 threads and not 12.. So if i set it to 9, its wrong or not? I dont have 12 threads. The i7-3930k and i7-4930k has 12 threads. So i wonder...
 

Boildown

Active Member
You're confusing cores with threads. Threads are software, cores are hardware. You can run 12 threads on a single core CPU if you really want. The x264 devs elected to spawn 1.5 threads for each core detected, as that resulted in more performance than a 1 to 1 thread to core relationship when x264 was being developed.
 
Top