Conversation
Three options: Full (native DPR), Balanced (1.5x), Performance (1x). Primarily helps on HiDPI/Retina displays where rendering at native pixel ratio is expensive. Setting is persisted in preferences and requires a reload to take effect.
Better out-of-the-box performance on HiDPI/Retina displays.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a View → Map Quality menu with three options to control the OpenLayers
pixelRatio:Motivation
On macOS with Retina displays, rendering at native 2x DPR means 4x the pixel count compared to 1x displays. This causes noticeable lag during pan/zoom on older hardware (e.g. 2017 MacBook Pro with AMD dGPU).
Changes
src/main/menu/view-menu.js— Map Quality submenu in View menusrc/main/preload/modules/preferences.js— IPC bridge forVIEW_MAP_QUALITYsrc/renderer/store/PreferencesStore.js— Persistence + event emissionsrc/renderer/components/map/Map.js— ApplypixelRatioat map construction; reload on changeNotes
pixelRatiocan only be set at Map construction time, so changing the setting triggers a page reload.