从去年Java One 2007到现在,WorldWind Java SDK已经推出将近一年了,上一个版本是去年12月发布的0.4。比起最初的版本,0.4的规模已经是空前扩大了,包和类的数量都有大大的增加。因为是处在开发的初期,所以每一个版本的变化都非常大,包的结构在不断的改变,之前版本上能跑的程序现在必需修改了。
0.4开始,WorldWind Java提供了一个WMSLayerFactory,用于简化和WMS服务的集成。之前的版本要加载一个WMS图层,需要集成TiledImageCache类,重写TiledUrlBuilder。而现在只要给WMSLayerFactory传入一个Capabilities对象和一个WMS的名值对分装类AVList,就可以获得相应的WMS图层。
取得Capabilities对象的方法是向服务器发送一个CapabilitiesRequest,在WMS的规范中就是getCapabilities请求,返回的将是一个XML文档,通过Capabilities的静态方法parse就可以获得Capabilities对象了。这个对象中包含了WMS服务器的基本信息,包括服务器上的所有图层极其范围等等,具体可以去参考WMS规范。
对于WMS的url的参数,需要构造一个AVList,以名值对的形式传入。这一块WorldWind也就行了简单的封装,常见的key都被分装在了AVKey接口中,无需手动书写。
最后,获得的WMS图层将添加到Model上,设置enable为true即可。
更多效果图请到:
http://www.classicning.com/blog/post/585.html
- 大小: 597.1 KB
- 大小: 509.3 KB
- 大小: 528.5 KB
分享到:
相关推荐
Integrating SystemC Models with Verilog and SystemVerilog.pdf
Integrating Direct3D 9.0 with MFC
Data-Driven_Stochastic_Unit_Commitment_for_Integrating_Wind_Generation
Integrating Python with Leading Computer Forensic Platforms takes a definitive look at how and why the integration of Python advances the field of digital forensics. In addition, the book includes ...
Time for action – integrating GeoServer and OpenLayers 196 Time for action – using GeoRSS with OpenLayers 199 Exploring Leaflet 201 Time for action – using Leaflet with GeoServer layers 201 Summary...
Microsoft.Press.Integrating.PHP.with.Windows.2011
Integrating Python with Leading Computer Forensics Platforms 英文epub 本资源转载自网络,如有侵权,请联系上传者或csdn删除 本资源转载自网络,如有侵权,请联系上传者或csdn删除
Oracle Receivables Guide to Integrating Oracle Receivables with Vertex Quantum Release 11i
Integrating Windows NT Server 4.0 with NetWare, UNIX, IBM, and
VTK 13 Integrating with the Windowing__ System.pdf VTK 13 Integrating with the Windowing__ System.pdf
Integrating Python with Leading Computer Forensics Platforms 英文无水印pdf pdf所有页面使用FoxitReader和PDF-XChangeViewer测试都可以打开 本资源转载自网络,如有侵权,请联系上传者或csdn删除 本资源...
Integrating Open-Source Statistical Packages with ArcGIS
Apress - Office and SharePoint 2010 Users Guide - Integrating SharePoint with Excel Outlook Access and Word
The book explains how to take advantage of dynamism, distribution, and automatic dependency provisioning, while still integrating with existing Java EE applications. The book is written for Java EE ...
hadoop 与oracle数据库的结合
• integrating a Java application with legacy code written in languages such as C or C++ • incorporating a Java virtual machine implementation into an existing application written in languages such ...
Integrating Supervised Subspace Criteria with Restricted Boltzmann Machine for Feature Extraction
• integrating a Java application with legacy code written in languages such as C or C++ • incorporating a Java virtual machine implementation into an existing application written in languages such ...