码迷,mamicode.com
首页 > 其他好文 > 详细

投影转换

时间:2016-01-12 11:39:00      阅读:251      评论:0      收藏:0      [点我收藏+]

标签:

   double locy = loc.getLatitude(); double locx = loc.getLongitude();
Point wgspoint = new Point(locx, locy);
Point mapPoint = (Point) GeometryEngine
.project(wgspoint,
SpatialReference.create(4326),
map.getSpatialReference());

//中点

 Envelope envelope = new Envelope();
graphic.getGeometry().queryEnvelope(envelope);
envelope.getCenter();

//投影转经纬度

SpatialReference sr4326 = SpatialReference.create(4326);

SpatialReference sr102100 = SpatialReference.create(102100);

Point point=(Point)graphic.getGeometry();
Point geometry=(Point)GeometryEngine.project(graphic.getGeometry(),sr102100, sr4326);
Geometry geometry1=GeometryEngine.project(b,graphic.getSpatialReference(), sr4326);
Point mapPoint = (Point) GeometryEngine.project(b, graphic.getSpatialReference(), sr4326);

投影转换

标签:

原文地址:http://www.cnblogs.com/xiongxiaolang/p/5123451.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!