I need to be able to read metadata from the monitor, like: gamma, and monitor name, and hopefully, monitor size. Will I have to probe the registry? (SetupAPI???)
I tried DXGI (IDXGIOutput::GetDesc) and WinAPI (EnumDisplayDevicesA).
BROKEN:
HRESULT hr = IDXGIOutput1_GetDesc(output, &monitor_desc);
if(FAILED(hr)) {
assert(0);
}
printf("monitor name: %s\n", monitor_desc.Description);
ALSO BROKEN:
DISPLAY_DEVICE display_device_desc = { sizeof display_device_desc };
EnumDisplayDevices(NULL, 0, &display_device_desc, 0);
EnumDisplayDevices(display_device_desc.DeviceName,0,&display_device_desc, 0);
printf("monitor name: %s\n", display_device_desc.DeviceString);
I get Generic PnP Monitor instead of the correct name, Hannspree HF225.