简体   繁体   English

自定义Google地图叠加?

[英]Custom Google Map overlay?

How can you use a custom tileset/overlay on a Google map, like was done here: 如何在Google地图上使用自定义图块集/叠加层,就像在此处所做的那样:

http://www.philaplace.org http://www.philaplace.org

That is pretty cool, and I would like to experiment with this. 这很酷,我想试试这个。

There are a couple different ways to do it. 有几种不同的方法可以做到这一点。 One way is to create a GTileLayer object and implement the getTileURL() to return the URL pointing to your tiles. 一种方法是创建一个GTileLayer对象并实现getTileURL()以返回指向您的tile的URL。

But first you'll need an image that's cut properly in the tile format. 但首先你需要一个以瓷砖格式正确切割的图像。 For starters, I'd recommend you look at MapTiler: http://www.maptiler.org/ It will cut images for you AND generate a GoogleMap with the overlay. 对于初学者,我建议您查看MapTiler: http//www.maptiler.org/它会为您剪切图像并生成带有叠加层的GoogleMap。

您需要查看Google地图API第3版的Google 叠加层 (尤其是自定义叠加层 )和自定义地图类型文档。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM