Question / Help Dual GPU Encoding w/ x264?

ImMadness

New Member
So I was curious if I were able to purchase a dedicated GPU to use for dealing with load on OBS with x264. Currently, I use medium preset, but my fps games use 80-90% of my GPU and obs uses about 10-15% on that x264 preset and because of that I get fps drops in higher usage times. So I was curious if there was a way I could purchase a second GPU to handle that additional load while still using x264 preset.

Current build:
RTX 2070
i9-9900x
32GB DDR4 3000Hz
 

koala

Active Member
A second GPU will not help. It will worsen things instead, because the pci-express bus bandwidth isn't reserved for one GPU any more (x16 speed) but will be halved for each card, that means x8 for each. It will also not being used at all if you use x264, because x264 only uses the CPU and no GPU.

You have a RTX 2070, which has a much improved nvenc hardware encoder. Its quality is between the quality of x264 medium and fast preset while requiring no CPU power. Use it and get rid of x264 bogging down your CPU.
 

muentzee

New Member
x8 would be enough for the RTX 2070 bandwidth, that would work. In general it could technically work with a second GPU. But then you wouldn't be "allowed" to use game capture and would have to use a capture card instead. So still not a good option.
 

ImMadness

New Member
A second GPU will not help. It will worsen things instead, because the pci-express bus bandwidth isn't reserved for one GPU any more (x16 speed) but will be halved for each card, that means x8 for each. It will also not being used at all if you use x264, because x264 only uses the CPU and no GPU.

You have a RTX 2070, which has a much improved nvenc hardware encoder. Its quality is between the quality of x264 medium and fast preset while requiring no CPU power. Use it and get rid of x264 bogging down your CPU.
This is actually false, if you'd look at task manager while using x264 it actually does use GPU, ~10% and the issue is dealing with games maxing my GPU, so if I switch to nvenc that would only make matters worse not better.
 

koala

Active Member
OBS will always use some GPU resources, because it does source compositing and video rendering on the GPU. This is not x264-specific but a sign of just OBS doing its work. If you force OBS to run on "the other" GPU, you're forcing OBS to use less efficient capture methods and copying the raw picture data two times more through the pci-express bus.

In a one GPU setup, the data is transferred from GPU memory to CPU memory once: after compositing the video. In a two GPU setup where OBS is running on the other GPU, the video data has to be moved from GPU#1 memory to CPU memory, from CPU memory to GPU#2 memory for video composition, and a third time as composited video back to CPU memory again. Together with the halved pci-express bandwidth, this may create a bottleneck that results in micro or not so micro stutters and general sloppiness of the system.

The best option to deal with frame drops due to high GPU usage is to limit the frame rate of the game you're capturing, so OBS gets enough resources to composite the video - on that GPU. OBS is a very resource intensive application, you cannot expect your game running as if it is running exclusively.
 
Top