You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
MGLMapSnapshotOptions.size should be measured in points #10088
MapKit parityFor feature parity with MapKit on iOS or macOSbugiOSMapbox Maps SDK for iOSmacOSMapbox Maps SDK for macOSrelease blockerBlocks the next final release
MGLMapSnapshotOptions.size is supposedly measured in pixels, but its type is CGSize, which is almost always measured in points when used with a screen coordinate system. (After all, the width and height can be fractional, whereas there’s no such thing as a fractional pixel.) Ideally, this property should remain CGSize-typed, but we should change MGLSnapshotter to convert to pixels behind the scenes.
I might be mistaken but I think it's measured in points but the minimum size is 64x64 in pixels, hence the confusion. #10105 fixes the incorrect scale.
MapKit parityFor feature parity with MapKit on iOS or macOSbugiOSMapbox Maps SDK for iOSmacOSMapbox Maps SDK for macOSrelease blockerBlocks the next final release
Activity
1ec5 commentedon Oct 2, 2017
Another reason to switch to points is for consistency with MapboxStatic.swift:
https://github.com/mapbox/MapboxStatic.swift/blob/b73aa38ddb02332fa04e2dfeb7abb50fd8ab1177/MapboxStatic/SnapshotOptions.swift#L213-L218
frederoni commentedon Oct 2, 2017
I might be mistaken but I think it's measured in points but the minimum size is 64x64 in pixels, hence the confusion. #10105 fixes the incorrect scale.
fabian-guerra commentedon Oct 4, 2017
Can we close this? We specify in the docs
MGLMapSnapshotOptions.sizeis measured in points. And @frederoni clarified in the comment above.1ec5 commentedon Oct 4, 2017
Yep, looks good now.