What is the most efficient and fundamental way to get cpu % usage and network throughput on windows platform?
Correct Me If I'm Wrong...
- windows api // Win32? SDK? (c/c++) #sorry, I have no idea...
- Windows Management Instrumentation (WMI),
- Win32_PerfFormattedData_Tcpip_NetworkInterface class BytesReceivedPerSec
- Win32_PerfRawData_PerfOS_Processor class PercentProcessorTime
- System.Diagnostics PerformanceCounter
- Performance Data Helper (PDH) , pdh.dll
- PerformanceCounter (c#/.net framework) or another nowaday method?
- NtQuerySystemInformation in ntdll.dll
So what is the best way to get this values, could I only import windows.h
and kernel32.dll to get both cpu percent usage and network interface speed values?
thanks