打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
how to zoom to layer

Zooming to a layer in globe

  1. To zoom to a layer in globe get a handle to the layer as shown in the following code example. To get a handle to a specific layer, pass in the layer index.

[C#]
ESRI.ArcGIS.Analyst3D.IScene scene = (ESRI.ArcGIS.Analyst3D.IScene)globe; // Explicit cast.ESRI.ArcGIS.Carto.ILayer layer = scene.get_Layer(layerIndex);
  1. Now, get the extent of the layer using the following code example:

[C#]
ESRI.ArcGIS.Geometry.IEnvelope envelope = layer.AreaOfInterest.Envelope;
  1. After getting the extent, the IGlobeCamera.SetToZoomToExtents method can be used to zoom to the extent of the layer. See the following code example:

[C#]
ESRI.ArcGIS.Analyst3D.ICamera camera = globeDisplay.ActiveViewer.Camera;ESRI.ArcGIS.GlobeCore.IGlobeCamera globeCamera = (ESRI.ArcGIS.GlobeCore.IGlobeCamera)camera; // Explicit cast.ESRI.ArcGIS.Analyst3D.ISceneViewer sceneViewer = globeDisplay.ActiveViewer;globeCamera.SetToZoomToExtents(envelope, globe, sceneViewer); 

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
Arcgis for js加载百度地图
arcgis api for javascript 学习(一) 调用在线发布的动态地图
arcgis api 4.x for js之基础地图篇
ArcGIS API for JavaScript实现地图双屏联动
ESRI的ArcGis视频分享
Arcscene二次开发部分开发C#
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服