mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
OpenGL: Take global scale factor into account when setting rendering scale on Windows
This commit is contained in:
parent
40ab91dea4
commit
05602341fc
1 changed files with 4 additions and 0 deletions
|
|
@ -285,6 +285,10 @@ public:
|
|||
|
||||
#if JUCE_WINDOWS && JUCE_WIN_PER_MONITOR_DPI_AWARE
|
||||
auto newScale = getScaleFactorForWindow (nativeContext->getNativeHandle());
|
||||
auto desktopScale = Desktop::getInstance().getGlobalScaleFactor();
|
||||
|
||||
if (! approximatelyEqual (1.0f, desktopScale))
|
||||
newScale *= desktopScale;
|
||||
#else
|
||||
auto newScale = displayScale;
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue