Question / Help Add option to select rendering GPU (like in OBS Classic)

steffend

New Member
My problem is:
I am using two GPUs: GTX 970 and Intel HD 4600. The main monitor is connected to the GTX while two other monitors are connected to the HD 4600. The GTX is used to render game content.
When using OBS Studio, it uses the GTX to render the scenes (RENDER, NOT ENCODE) which does, on the one hand, impact gaming perfomance drastically. On the other hand I'm not able to capture one of the other screens connected to the HD 4600 using monitor capturing mode, only the one connected to the GTX is showing up (which makes sense, when using the GTX to render).

In OBS Classic I can chose the HD 4600 to render the scenes just by selecting it in the OBS settings. This makes my GTX 970 run smoothly in games while the HD 4600 can render other content without any impact on gaming performance.

When combining this with Dxtory I can smoothly capture gaming footage from any game, without impacting the gaming performance at all. dxtory captures the content, passes it to OBS Classic. OBS Classic uses the Intel GPU to render 1440p60 Video from the DirectShow source, then encodes it using the dedicated H264 encoder of the GTX. This way I achieve smooth 60fps records with games that cause permanent stuttering with only 20fps in OBS Studio using the GTX.

So: is there any way to force OBS Studio to run on the HD 4600? Or am I stuck using OBS classic? Why isn't there any option to select the rendering GPU?

If I cannot do this with OBS Studio, consider it as a feature request :)

Example:
https://ibin.co/3SYF88vjSYvd.png (OBS Classic, smooth 60fps when capturing What Remains of Edith Finch, 1440p60)
https://ibin.co/3SYFSRAX6dgb.png (GPU Usage when using OBS Studio, 1440p60, GTX most of the time at 99%)
https://ibin.co/w800/3SYFfrXg6SaL.png (OBS Studio statistics)
 

Cobra_Fast

New Member
Was there any progress made on this?
I have two Nvidia GPUs and would like to use the secondary one for rendering content too.
 

R1CH

Forum Admin
Developer
No. The moment you add any hardware accelerated capture you would have to transfer data between GPU memory which kills performance. It doesn't take much GPU to do compositing in OBS to begin with.
 

Cobra_Fast

New Member
That's a good point I didn't think about before.

I just found out Microsoft is testing a feature that might allow me to try letting OBS render on the second GPU. Just have to wait till it comes out, probably in the 2021 spring update.
 

koala

Active Member
You cannot overcome hardware limits by any kind of software. If you capture from one GPU and encode on another GPU, the raw video data has to be transferred through the pci-express bus from one GPU to the other. This transfer is obligatory to make the data available to the encoder. Doing this consumes more resources than encoding on a second GPU will save.

Especially with Nvenc, because Nvenc has two features that support direct encoding. The first is directly encoding from the frame buffer of the GPU instead of moving data around. You thwart this by using a second GPU for encoding, because nvenc on one GPU cannot access data from memory of a different GPU. The second is Nvenc is a dedicated circuit on the GPU. It doesn't use up computing resources. It doesn't take away GPU resources from some game or other app while encoding. It's simply not needed to outsource encoding to an external encoder to save or load balance computing resources.
 
Top