OBS is using only 7 out of 20 cpu cores?

DeMoN

Member
A friend got a very nice friend giving him hardware for 800 € at christmas
So he got now a 14700KF, DDR5 6000 MT/s RAM and so on

But that friend has no job, so he still has only a RTX 3060 which is constantly maxed out 100%, while the CPU is super duper bored.
So it makes for his situation perfect sense to use the CPU for good use and use x264 Encoding for videocapture. Better quality than NVEnc as well.

Using ffmpeg for a test encode, we found out that it can encode at 1080p with preset slow at 150fps which is amazing good. I envy him, my 9900k cant do that the slightest :D

So we thought: wow - perfect, x264 slow at recording easily possible with this fps value.
Then to our surprise it was encoder lag in OBS reported while recording a game. Only at preset fast it was ok. And we didnt understand the world anymore.

Then we looked at task manager and to our shock:

OBS uses only 7 out of the 20 cpu cores o.o

Thats really, really dumb. Why is that? No wonder the encoding is so slow in OBS
And it does it on both output methods, internal and also ffmpeg output.

And for the ffmpeg output it is weird, because in that case its clearly OBS instructing ffmpeg to use only these 7 cores.

Because obviously if we use ffmpeg without OBS, it used all 20 cores...

I understand that it shouldnt use all 20 to keep a little bit cpu available for the game, but using only 7 cores is dumb
and OBS would only need to maintain 60fps, not the full 150 the cpu is capable to do. So there would be even headroom left if using 20 cores
so it probably would be totally fine using 16 cores

Can I somehow change this? Because this is really annoying.
 

rockbottom

Active Member
I don't seem to have that issue. OBS v30.2.2

1737724914940.png
 

DeMoN

Member
In an other discord channel someone had the theory that OBS might only see the P-Cores.
But looking at your image it indeed uses all cores, including e-cores. hmm.
Maybe OBS has this problem only at windows 10? Its really weird, because other software uses all cores
 

rockbottom

Active Member
I'm also running W10.

The number of cores being utilized changes depending on the Preset in play. Slower was in play above. With the Slow Preset, 10 P-cores & all e-cores are going with the rest seeing just minor utilization.
 

DeMoN

Member
if it would work right, it would use all 20 cores like the ffmpeg commandline exe always does. and all cores at 100% usage.
In OBS there is for him only 7 cores at 100% usage and all others at 0% usage.
ffmpeg.exe uses all 20 cores on preset fast at 100% usage. Its clearly an OBS issue.
 

MrStevee

New Member
I don't seem to have that issue. OBS v30.2.2

View attachment 110892
I checked whether this error exists with the latest version.
So I used your version.
And I have to say that it has exactly the same problem.
The question that now arises for me is: Is OBS still not able to handle the 14th generation of Intel?
Because as De-M-oN already mentioned, other programs can use all cores.
 

rockbottom

Active Member
If it was OBS, I would get the same results on my system but it's not, so it could be settings or something else. Post the log(s) of your test(s).
 

rockbottom

Active Member
Operator error...

So if you're not inserting anything in the Video Encoder Settings (If Any) box, x264 is @ Default setting(s). When I tested a few minutes ago, only 1 P Core & all of my e-cores were utilized.

Writing library :x264 core 164 r3106 eaa68fa
Encoding settings :cabac=1 / ref=1 / deblock=1:0:0 / analyse=0x3:0x113 / me=hex / subme=2 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=0 / me_range=16 / chroma_me=1 / trellis=0 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=0 / threads=34 / lookahead_threads=8 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=1 / b_bias=0 / direct=1 / weightb=1 / open_gop=0 / weightp=1 / keyint=30 / keyint_min=3 / scenecut=40 / intra_refresh=0 / rc_lookahead=10 / rc=crf / mbtree=1 / crf=23.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / ip_ratio=1.40 / aq=1:1.00
 

rockbottom

Active Member
I'm using OBS v30.2.2. This note in the log about the Video Encoder settings in the Custom Output is incorrect & was causing failures. Not sure if it's been updated in the version you are using.
09:03:19.027: If you're trying to set x264 parameters, use x264-params=name=value:name=value

Anyway, this works with no failures.
x264-params=ref=5;me=hex;subme=8;mixed_ref=1;trellis=2;chroma_qp_offset=-2;lookahead_threads=5;direct=3;weightp=2;keyint_min=25;rc_lookahead=50;crf=15
 

MrStevee

New Member
@MrStevee
Code:
11:01:49.065: Output 'adv_ffmpeg_output': stopping
11:01:49.065: Output 'adv_ffmpeg_output': Total frames output: 89376
11:01:49.065: Output 'adv_ffmpeg_output': Total drawn frames: 89378
this is "Custom Output (FFmpeg)". Thus, the settings for encoder should be specified manually in a text form.
Maybe you run into this issue: https://obsproject.com/forum/thread...r-where-do-i-find-the-option-for-that.183604/ ?
It doesn't matter whether you use ffmpeg or standard.
I've tried both.
The same number of cores in both.
 

MrStevee

New Member
Operator error...

So if you're not inserting anything in the Video Encoder Settings (If Any) box, x264 is @ Default setting(s). When I tested a few minutes ago, only 1 P Core & all of my e-cores were utilized.

Writing library :x264 core 164 r3106 eaa68fa
Encoding settings :cabac=1 / ref=1 / deblock=1:0:0 / analyse=0x3:0x113 / me=hex / subme=2 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=0 / me_range=16 / chroma_me=1 / trellis=0 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=0 / threads=34 / lookahead_threads=8 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=1 / b_bias=0 / direct=1 / weightb=1 / open_gop=0 / weightp=1 / keyint=30 / keyint_min=3 / scenecut=40 / intra_refresh=0 / rc_lookahead=10 / rc=crf / mbtree=1 / crf=23.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / ip_ratio=1.40 / aq=1:1.00

"Fast"
Because not all cores are used in OBS
 

Attachments

  • Screenshot_19.png
    Screenshot_19.png
    2 KB · Views: 9

rockbottom

Active Member
There was no encoding lag in your log, so what's the problem with it only using what's required to get the job done?

Windows Gaming: Game Mode can be enabled. Leave Game Bar & Game DVR (Captures) disabled.

I noticed your Odyssey is running 10-bit color (HDR), it should be 8-bit. Overall performance will improve without the color conversion.
10:34:09.304: bits_per_color=10

Some housekeeping is in order, some Scenes have Multiple Display, Game Or Window captures. Only (1) per to avoid interference.
 

MrStevee

New Member
What's the problem?
Just what De-M-oN posted.
I have a 20 core CPU, but OBS only uses 7 cores.
And that's why we had to use the "fast" preset.
Although more would be possible if OBS would use more cores.
 
Last edited:

DeMoN

Member
There was no encoding lag in your log, so what's the problem with it only using what's required to get the job done?
He could use preset slow with his cpu.

I noticed your Odyssey is running 10-bit color (HDR), it should be 8-bit. Overall performance will improve without the color conversion.
10:34:09.304: bits_per_color=10

Thats just the display output of 10bit depth.
Screenshot 2024-10-15 212331.png


HDR is off.

Some housekeeping is in order, some Scenes have Multiple Display, Game Or Window captures. Only (1) per to avoid interference.
There is game and monitor capture, but obviously one of them is always off.

Man we didnt start OBS the first time.

We dont have performance issue, we have issue that it doesnt use all cpu cores.
 
Last edited:
Top