ArcGIS Web API 接入E都市瓦片
分享
接入E都市也类似于google的瓦片,只是空间参考可控制性不强,但是E都市本身也不是用的常规空间参考,所以这样接进来不影响看得效果就可以了。
文章来源:http://blog.csdn.net/sydbc/article/details/17258061
publicclassEdushi :TiledMapServiceLayer
{
publicoverridevoid Initialize()
{
this.FullExtent = new ESRI.ArcGIS.Client.Geometry.Envelope(-20037508.342787, -20037508.342787, 20037508.342787, 20037508.342787);
{
SpatialReference = new ESRI.ArcGIS.Client.Geometry.SpatialReference(102100);
};
this.SpatialReference = new ESRI.ArcGIS.Client.Geometry.SpatialReference(102100);
this.TileInfo = new TileInfo()
{
Height = 256,
Width = 256,
Origin = new ESRI.ArcGIS.Client.Geometry.MapPoint(-20037508.342787, 20037508.342787)
{
SpatialReference = new ESRI.ArcGIS.Client.Geometry.SpatialReference(102100)
},
Lods = new Lod[4]
};
double resolution = 9783.93962049996/4;
for (int i = 0; i <TileInfo.Lods.Length; i++)
{
TileInfo.Lods = new Lod() { Resolution = resolution };
resolution /= 2;
}
base.Initialize();
}
publicoverridestring GetTileUrl(int level, int row, int col)
{
string url = null;
if (level == 0)
{
url = “http://cpic2.edushi.com/cn/che ... c/png” + (3 – level) + “/” + (col – 25) + “,” + (row – 25) + “.png”;
}
if (level == 1)
{
url = “http://cpic2.edushi.com/cn/che ... c/png” + (3 – level) + “/” + (col – 50) + “,” + (row – 50) + “.png”;
}
if (level == 2)
{
url = “http://cpic2.edushi.com/cn/che ... c/png” + (3 – level) + “/” + (col – 100) + “,” + (row – 100) + “.png”;
}
if (level == 3)
{
url = “http://cpic2.edushi.com/cn/che ... c/png” + (3 – level) + “/” + (col – 200) + “,” + (row – 200) + “.png”;
}
return url;
}
}
文章来源:http://blog.csdn.net/sydbc/article/details/17258061
0 个评论
推荐内容
- ArcGIS Pro 2.4向独立server发布服务步骤
- Linux上安装ArcGIS Enterprise超详细教程——以Redhat7.2上安装ArcGIS Enterprise 10.5为例
- ArcGIS for Server 10.x 许可授权手册
- Portal for ArcGIS 10.X许可授权手册 (Windows版)
- arcgis server 无法手动删除切片
- ArcGIS for Server内置JS Viewer的离线部署和配置
- Linux上安装ArcGIS for Server超详细教程——以Redhat6.5上安装ArcGIS for Server 10.3.1为例
- 如何创建Geometry Service?
- 地图服务优化策略
相关问题
- 如何优雅的使用ArcGIS知乎?
- 建设ArcGIS知乎平台的目和意义?
- ArcGIS知乎社区改进意见征集
- 【抽奖结果已出】ArcGIS知乎社区活动 之 你不知道的地理空间革命【转发分享有奖】【附奖品寄送照片】
- 苹果系统下可以使用arcgis 吗?
- 请问ArcGIS适合在局域网内用javaweb做二次开发吗?
- arcgis版本兼容性
- ArcGIS 知乎社区活动 之 字幕组加鸡腿暨KBP字幕组招新【获奖名单公布与优秀作品展示】
- ArcGIS 知乎社区活动 之 2018拒绝boring,来,在线答题赢kindle【结果已出,速来领奖】
- 请问大神们,怎么用ArcGIS做城镇间经济联系强度的图?
- 在Visual studio 2015 中使用 Arcgis API for JavaScript v3.16 如何实现代码智能提示?