GPU eco check

This commit is contained in:
Serge
2023-05-09 16:13:35 +02:00
parent 07020c3561
commit ac19a822f7
2 changed files with 26 additions and 10 deletions

View File

@@ -1,4 +1,5 @@
using System.Management;
using GHelper;
using System.Management;
using System.Runtime.InteropServices;
public class ASUSWmi
@@ -218,6 +219,20 @@ public class ASUSWmi
return CallMethod(DSTS, args);
}
public int SetGPUEco(int eco)
{
int ecoFlag = DeviceGet(GPUEco);
if (ecoFlag < 0) return -1;
if (ecoFlag == 1 && eco == 0)
return DeviceSet(GPUEco, eco, "GPUEco");
if (ecoFlag == 0 && eco == 1)
return DeviceSet(GPUEco, eco, "GPUEco");
return -1;
}
public int SetFanCurve(int device, byte[] curve)
{