MapXL / route-me

Automatically exported from code.google.com/p/route-me
0 stars 0 forks source link

Tiles for the retina display #149

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?

1. Using route-me on an iOS device with a retine display.

With Apple's new retina display using tile based maps has become a problem due 
to the fact that bitmap graphics don't scale.
To circumvent that problem Google has rendered new tiles for the use in the 
Maps.app. For a given zoom level those tiles have a resolution which is twice 
as high.

It would be nice to have the same feature in route-me, assuming you have your 
own tile source with retina-compatible tiles. It's probably mostly about 
inserting a factor of 2 in a few calculations (projection/tile management).

Looking forward to your ideas!

Original issue reported on code.google.com by phys...@googlemail.com on 7 Oct 2010 at 9:12

GoogleCodeExporter commented 8 years ago
I just solved this, I think. Patch against r633 attached.

1. Create an extra property on RMMapContents, scaledMetersPerPixel, which 
simply divides (surprisingly, not multiplies) metersPerPixel by the screen 
scale factor.  
2. Pass this, in place of metersPerPixel, to the tile projection in 
-[RMMapContents tileBounds].
3. Alter -[RMTileLoader screenIsLoaded] to use scaledMetersPerPixel when 
calculating targetZoom.

Original comment by michael@tyson.id.au on 8 Oct 2010 at 9:23

Attachments: