ThePhD / infoware

C++ Library for pulling system and hardware information, without hitting the command line.
Creative Commons Zero v1.0 Universal
410 stars 84 forks source link

[windows] retrieve logical DPI, physical resolution and more display information #67

Closed ffiirree closed 1 year ago

ffiirree commented 1 year ago

As described in the issue #66 , the infoware can not retrieve correct logical DPI and physical resolution of each display: Before:

Displays:
    #1:
      Resolution  : 2560x1440
      DPI         : 96
      Colour depth: 32b
      Refresh rate: 59Hz
    #2:
      Resolution  : 1280x720
      DPI         : 96
      Colour depth: 32b
      Refresh rate: 50Hz

Now:

  Displays:
    #1:
      Resolution  : 2560x1440
      Logical DPI : 96
      Colour depth: 32b
      Refresh rate: 59Hz
      Position    : 0, 0
      Scale factor: 100%
      Primary     : 1
      Orientation : Landscape
    #2:
      Resolution  : 1920x1080
      Logical DPI : 144
      Colour depth: 32b
      Refresh rate: 50Hz
      Position    : -1079, -1080
      Scale factor: 150%
      Primary     : 0
      Orientation : Landscape (flipped)

The behavior: