As I got some PNs that the link I've posted in the sticky thread 4 years ago is dead and other users still need the source code, I'll upload it again.
With this source code, C# developers can conveniently access the shared memory (and therefore the data) provided by GPU-Z within their programs.
Here's a link to a newly created .zip archive which includes two visual studio 2010 projects, one that's written in C++ and used to create a .dll and the other one to show how you can access the shared memory via the .dll in C#. Usually including the .dll into your project (such as done in the demo project) will be sufficient, but if that doesn't work, you might try to adjust/compile the .dll project by yourself. I've also compiled a x64 version of the .dll, but normally the 32 bit version should work also on all 64 bit OS.
Here is a short snippet from the demo project, showing how the shared memory can be accessed:
Code:
Output:
The C# code is pretty straight forward. Please don't mind that I might have not used some fancy C# stuff that would have made the GpuzWrapper more convenient, but actually I'm a Java developer that programmed the whole thing 4 years ago..
Feel free to enjoy the demo and ask if something is unclear.
Here are some links to download it:
http://www.file-upload.net/download-4266506/GpuzShMem.zip.html
http://www.filedropper.com/gpuzshmem
https://github.com/JohnnyUT/GpuzShMem/zipball/master
And here is the link to the github project, if you want to take a look at the sources without downloading the whole archive:
https://github.com/JohnnyUT/GpuzShMem
PS: You might have to update the location of the GpuzShMem.dll file in the GpuzDemo project. I think visual studio uses the absolute path. -.-

Here's a link to a newly created .zip archive which includes two visual studio 2010 projects, one that's written in C++ and used to create a .dll and the other one to show how you can access the shared memory via the .dll in C#. Usually including the .dll into your project (such as done in the demo project) will be sufficient, but if that doesn't work, you might try to adjust/compile the .dll project by yourself. I've also compiled a x64 version of the .dll, but normally the 32 bit version should work also on all 64 bit OS.
Here is a short snippet from the demo project, showing how the shared memory can be accessed:
Code:
Code:
GpuzWrapper gpuz = new GpuzWrapper();
gpuz.Open();
Console.WriteLine(gpuz.DataKey(0) + ": " + gpuz.DataValue(0));
Console.WriteLine(gpuz.SensorName(0) + ": " + gpuz.SensorValue(0) + " " + gpuz.SensorUnit(0));
gpuz.Close();
Output:
Code:
DirectXSupport: 11.0
GPU Core Clock: 732,1149 MHz
The C# code is pretty straight forward. Please don't mind that I might have not used some fancy C# stuff that would have made the GpuzWrapper more convenient, but actually I'm a Java developer that programmed the whole thing 4 years ago..

Feel free to enjoy the demo and ask if something is unclear.
Here are some links to download it:
http://www.file-upload.net/download-4266506/GpuzShMem.zip.html
http://www.filedropper.com/gpuzshmem
https://github.com/JohnnyUT/GpuzShMem/zipball/master
And here is the link to the github project, if you want to take a look at the sources without downloading the whole archive:
https://github.com/JohnnyUT/GpuzShMem
PS: You might have to update the location of the GpuzShMem.dll file in the GpuzDemo project. I think visual studio uses the absolute path. -.-
Last edited: