How can I read Nvidia GPU usage in C#?

Asked 2 years ago, Updated 2 years ago, 166 views

Hello? I'm working on a program that sprays GPU usage on the screen by reading GPU usage on C#.Net, but I don't know how to read GPU usage on C#. I would appreciate it if you could let me know in detail if there is a way to read the API or usage.

c# gpu

2022-09-22 18:51

1 Answers

It's a little difficult with c# alone, and you have to use c/c++.(Of course, if you need to compile the source, and if you have nvapi.dll, you don't need it. It's probably in the directory of the nvidia program. I'm not currently in Windows, so it's hard to check.)

First of all, it would be most accurate to use NVAPI, the NVIDIA's core software development kit.

https://developer.nvidia.com/gameworksdownload#?search=nvapi

I found out that there is already a project to wrap nvapi.dll with c#.

https://github.com/falahati/NvAPIWrapper

You can add the assembly with nuget and look at the sample.


2022-09-22 18:51

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.