等高线地图(骑行地图):能访问
http://a.tile.opencyclemap.org/cycle/10/265/420.png
openstreetmap:能访问,但是经纬度坐标为大地坐标
http://a.tile.openstreetmap.org/15/5582/13084.png
http://a.tile.openstreetmap.org/6/53/26.png
vmap0:能访问,BBOX可以是任何经纬度范围,自动拉伸到256*256
http://vmap0.tiles.osgeo.org/wms/vmap0?LAYERS=basic&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&FORMAT=image%2Fjpeg&SRS=EPSG%3A4326&BBOX=-90,45,-45,90&WIDTH=256&HEIGHT=256
Vmap0 是美国国家图像与测绘局(现“国家地理空间情报局”)世界数字海图的升级版
百度地图访问URL:能访问
http://online1.map.bdimg.com/tile/?qt=tile&x=793&y=293&z=12&styles=pl&udt=20150305&scaler=1
谷歌地图:http://www.google.cn/maps能访问,但是得不到url
https://map.baidu.com/也得不到百度的url
http://ditu.google.cn/maps/api/js?v=3.exp&sensor=false
http://maps.google.com/maps/访问不了
http://www.google.cn/maps/vt/pb=!1m4!1m3!1i{z}!2i{x}!3i{y}!2m3!1e0!2sm!3i380072576!3m8!2szh-CN!3scn!5e1105!12m4!1e68!2m2!1sset!2sRoadmap!4e0!5m1!1e0
天地图:能访问(http://map.tianditu.com/得到)
http://t1.tianditu.com/DataServer?T=cva_w&x=6749&y=3103&l=13
欧洲土壤中心WMS服务:不能访问
http://eusoils.jrc.ec.europa.eu/wrb/wms_Threats.asp?&SERVICE=WMS&REQUEST=GetCapabilities
美国雷达地图:能访问(与vmap0类似)
http://mesonet.agron.iastate.edu/cgi-bin/wms/nexrad/n0r.cgi?service=wms&request=getcapabilities ------OK
http://mesonet.agron.iastate.edu/cgi-bin/wms/nexrad/n0r.cgi?LAYERS=nexrad-n0r&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&FORMAT=image%2Fjpeg&SRS=EPSG%3A4326&BBOX=-90,38.671875,-89.296875,39.375&WIDTH=256&HEIGHT=256 ------OK
esri与开源
http://www.esri.com/news/arcnews/spring11articles/open-source-technology-and-esri.html
http://www.esri.com/software/open
EPSG(The European Petroleum Survey Group, http://www.epsg.org/ )维护着空间参照对象的数据集,OGC标准中空间参照系统的SRID(Spatial Reference System Identifier)与EPSG的空间参照系统ID相一致。
web墨卡托(不能用于测量,误差很大):EPSG:900913 EPSG:3785
WGS 84:EPSG:4326
由于Google退出中国,导致http://maps.google.com/maps/不能访问,所以原来的openlayers加载GoogleMap的方法不用使用(包括书上的方法),经测试以下方法可以访问:(参考:http://fiftyk.iteye.com/blog/1773520)
OpenLayers.Layer.GMapLayer = OpenLayers.Class(OpenLayers.Layer.XYZ, {
wrapDateLine:true,
sphericalMercator:true,
urlTpl:"&hl=zh-CN&gl=CN&src=app&x=${x}&y=${y}&z=${z}",
/**
* @constructor
* @param {String} name
* @param {String} url
* @param {Object} options
*/
initialize:function(name,url,options){
options = OpenLayers.Util.applyDefaults({},
options);
OpenLayers.Layer.XYZ.prototype.initialize.apply(this,
[name,url,options]);
},
getURL: function (bounds) {
var xyz = this.getXYZ(bounds);
var url = this.url;
if (OpenLayers.Util.isArray(url)) {
var s = '' + xyz.x + xyz.y + xyz.z;
url = this.selectUrl(s, url) + this.urlTpl;
}
return OpenLayers.String.format(url, xyz);
},
destory:function(){
this.sphericalMercator = null;
this.urlTpl = null;
OpenLayers.Layer.XYZ.prototype.destroy.apply(this, arguments);
},
clone:function(obj){
if(obj == null){
obj = new OpenLayers.Layer.GMapLayer(this.name,this.url,
this.getOptions());
}
obj = OpenLayers.Layer.XYZ.prototype.clone.apply(this,[obj]);
return obj;
},
getXYZ:function(bounds){
var res = this.getServerResolution();
var x = Math.round((bounds.left - this.maxExtent.left) /
(res * this.tileSize.w));
var y = Math.round((this.maxExtent.top - bounds.top) /
(res * this.tileSize.h));
var z = this.getServerZoom();//继承自Grid
if (this.wrapDateLine) {
var limit = Math.pow(2, z);
x = ((x % limit) + limit) % limit;
}
return {'x': x, 'y': y, 'z': z};
},
CLASS_NAME: "OpenLayers.Layer.GMapLayer"
});
var map = new OpenLayers.Map("map",{
layers:[
new OpenLayers.Layer.GMapLayer("Google卫星图层",
["http://mt1.google.cn/vt/lyrs=s@123"]),
new OpenLayers.Layer.GMapLayer("Google标注图层",
["http://mt2.google.cn/vt/imgtp=png32&lyrs=h@205000000"]),
new OpenLayers.Layer.GMapLayer("Google矢量图层",
["http://mt1.google.cn/vt/lyrs=m@205000000"]),
new OpenLayers.Layer.GMapLayer("Google地形图层",
["http://mt1.google.cn/vt/lyrs=t@130,r@205000000"]),
new OpenLayers.Layer.GMapLayer("Google路况图层",
["http://mt0.google.com/vt?lyrs=m@205000000,traffic|seconds_into_week:-1"])
]
,center:new OpenLayers.LonLat(120.30549379552448,31.55342767838905),
});
//图层切换控件
map.addControl(new OpenLayers.Control.LayerSwitcher());
//鹰眼控件
map.addControl(new OpenLayers.Control.OverviewMap());
map.addControl(new OpenLayers.Control.MousePosition());