| Summary: | Request: provide SDL_GetWindowDPIScale() for use without renderer or gl context | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Ellie <etc0de> |
| Component: | video | Assignee: | Sam Lantinga <slouken> |
| Status: | NEW --- | QA Contact: | Sam Lantinga <slouken> |
| Severity: | enhancement | ||
| Priority: | P2 | ||
| Version: | 2.0.10 | ||
| Hardware: | x86_64 | ||
| OS: | All | ||
|
Description
Ellie
2020-03-11 14:03:48 UTC
I just read somewhere that SDL_GetDisplayDPI() returns or used to return the physical DPI, not necessarily the virtual one. Therefore, I change my suggestion to name this new function: SDL_GetWindowDPIScale(), returning 1.0 without HighDPI, and 2.0 or whatever the scale factor is in a HighDPI setting. I really wasn't thinking of the physical DPI when making this API change request, but indeed the actual upscale factor used for rendering. |