blob: 60272f1afa071abeaadaf3db998dafdbf69bcc6f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
using System.Runtime.InteropServices;
namespace Ryujinx.Common.System
{
public static class ForceDedicatedGpu
{
public static void Nvidia()
{
if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
{
// NOTE: If the DLL exists, we can load it to force the usage of the dedicated Nvidia Gpu.
NativeLibrary.TryLoad("nvapi64.dll", out _);
}
}
}
}
|