Giter Club home page Giter Club logo

Comments (5)

trasch avatar trasch commented on September 13, 2024

That's exactly how I do it, although I have a few more requirements. CATiledLayer is actually quite smart in that it really only loads the visible tiles, so enlarging the map view is not much of a problem (in my experience, at least).

from route-me.

incanus avatar incanus commented on September 13, 2024

Ok, just curious. The one problem I've seen with this approach is if the map stays rotated, getting to the bounds or constraints does weird things, since they are technically out of view because of the rotation corner-covering. But for Maps.app-like behavior where if you pan, the map rotates back to normal orientation, it works fine (providing you aren't physical located near the meridian or the poles).

from route-me.

trasch avatar trasch commented on September 13, 2024

My solution was to always rotate back to the normal orientation as soon as the user interacts with the map, like Maps.app. If you don't want to do this, then you'll have to take the rotation into account for every constraint or bound which might not be worth the work...

from route-me.

incanus avatar incanus commented on September 13, 2024

Yeah, that's what I'm doing. I've added a pinch & zoom simultaneous gesture which only serves to un-rotate the map if the center point gets moved.

from route-me.

incanus avatar incanus commented on September 13, 2024

FYI, the way I've tackled this over in #59 location services was to set clipsToBounds = YES for RMMapView itself but NO for the contained UIScrollView, then rotate the scroll view inside of the map view. That way, overlays get rotated as well.

from route-me.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.