diff options
author | Justin R. Miller <incanus@users.noreply.github.com> | 2015-02-10 15:27:14 -0800 |
---|---|---|
committer | Justin R. Miller <incanus@users.noreply.github.com> | 2015-02-10 15:27:14 -0800 |
commit | 4fe94a202bb19499a0baf5795dede51550ee038c (patch) | |
tree | cc51e6b5217159ecb0f49c2bf16fa1a40b5bc4bc /platform | |
parent | c3d41828b6d95fa959088d1c37bb5c17fbc1e8c3 (diff) | |
parent | 49e76dba951aa232e24b988981e7bd8532b254c5 (diff) | |
download | qtlocation-mapboxgl-4fe94a202bb19499a0baf5795dede51550ee038c.tar.gz |
Merge pull request #845 from mapbox/scale-factor-3
fixes #621: better performance for iPhone 6 Plus through smaller render buffer
Diffstat (limited to 'platform')
-rw-r--r-- | platform/ios/MGLMapView.mm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/platform/ios/MGLMapView.mm b/platform/ios/MGLMapView.mm index 4328b46000..7c1f9eb657 100644 --- a/platform/ios/MGLMapView.mm +++ b/platform/ios/MGLMapView.mm @@ -202,6 +202,9 @@ mbgl::DefaultFileSource *mbglFileSource = nullptr; _glView.enableSetNeedsDisplay = NO; _glView.drawableStencilFormat = GLKViewDrawableStencilFormat8; _glView.drawableDepthFormat = GLKViewDrawableDepthFormat16; + if ([UIScreen instancesRespondToSelector:@selector(nativeScale)]) { + _glView.contentScaleFactor = [[UIScreen mainScreen] nativeScale]; + } _glView.delegate = self; [_glView bindDrawable]; [self addSubview:_glView]; |