4

It seems to be a known fact that MKMapView (and Google's maps in general) have a varying offset on 100-600m which makes annotations display incorrectly on the map.

According to this thread, Google has a private method called _applyChinaLocationShift, and it works, but apparently only for CLLocations that are given by CLLocationManager. For arbitrary CLLocations, it returns nil. The app I'm writing only needs to work in one city, so I've thought of pre-sampling the area using _applyChinaLocationShift and store the inverse transforms in the shipped app if that was possible.

So basically, is there any way to convert a coordinate to a coordinate that corresponds to the transformed China maps?

Community
  • 1
  • 1
Anton
  • 5,932
  • 5
  • 36
  • 51
  • 3
    It's said that there's some formula or database to transform "Mars coordinates" to real ones, but I never got any of them working. Later I turned into an Chinese local map provider. I can't really use your way as I need coordinate of the entire country. This (force map providers to add offset to coordinates) is one good example of how silly this government could be. – Zhao Xiang Sep 01 '12 at 19:53

1 Answers1

2

How about using location simulation in the Simulator and feeding it a bunch of coordinates in that particular city.

nevan king
  • 112,709
  • 45
  • 203
  • 241