aboutsummaryrefslogtreecommitdiff
path: root/src/Ryujinx.Common/GraphicsDriver/NVAPI/NvdrsSetting.cs
blob: a36781bafc66b943578024ecdf7f779fb9603eda (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
using System.Runtime.InteropServices;

namespace Ryujinx.Common.GraphicsDriver.NVAPI
{
    enum NvdrsSettingType : uint
    {
        NvdrsDwordType,
        NvdrsBinaryType,
        NvdrsStringType,
        NvdrsWstringType,
    }

    enum NvdrsSettingLocation : uint
    {
        NvdrsCurrentProfileLocation,
        NvdrsGlobalProfileLocation,
        NvdrsBaseProfileLocation,
        NvdrsDefaultProfileLocation,
    }

    [StructLayout(LayoutKind.Explicit, Size = 0x3020)]
    struct NvdrsSetting
    {
        [FieldOffset(0x0)]
        public uint Version;
        [FieldOffset(0x4)]
        public NvapiUnicodeString SettingName;
        [FieldOffset(0x1004)]
        public Nvapi SettingId;
        [FieldOffset(0x1008)]
        public NvdrsSettingType SettingType;
        [FieldOffset(0x100C)]
        public NvdrsSettingLocation SettingLocation;
        [FieldOffset(0x1010)]
        public uint IsCurrentPredefined;
        [FieldOffset(0x1014)]
        public uint IsPredefinedValid;

        [FieldOffset(0x1018)]
        public uint PredefinedValue;
        [FieldOffset(0x1018)]
        public NvapiUnicodeString PredefinedString;

        [FieldOffset(0x201C)]
        public uint CurrentValue;
        [FieldOffset(0x201C)]
        public NvapiUnicodeString CurrentString;
    }
}