使用Java和任何外部库,如何将纬度/经度点绘制到地球的图形表示中? [英] Using Java and any external libraries, how can I draw latitude/longitude points onto a graphical representation of the Earth?

查看:143
本文介绍了使用Java和任何外部库,如何将纬度/经度点绘制到地球的图形表示中?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前正在使用 Java Map Projection Library (我能够从作者那里获取用于Applet的代码并修改它以便在桌面应用程序中使用 - 不确定他是否与他的网站上的链接相关联)在应用程序中绘制地球地图。但是,我想更进一步。我有一组我想在这张地图上绘制的纬度/经度点 - 我只需要在每个点画一个圆圈,也许需要在地图上画一些连接圆圈(点)的线条。但是,由于用户使用内置的平移和缩放功能,因此需要在适当的位置重绘点。我能够实现的最好的是在缩放时保持点数,即使这样,当你放大时点也会变大。

I'm currently using the Java Map Projection Library (I was able to obtain the code used for the Applet from the author and modify it for use in a desktop application - not sure if he linked to that on his website yet) to draw a map of the Earth in an application. However, I want to take this a step further. I have a set of latitude/longitude points that I want to plot on this map - I just need to draw a circle at each point and perhaps some lines connecting the circles (points) on the map. However, as the user uses the built-in panning and zooming capabilities, the points need to be redrawn in the proper position. The best I have been able to achieve is maintaining the points when zooming, and even then the points get larger as you zoom in.

我完全愿意切换库但是我真的没有找到一个可以处理世界地图的图书馆,特别是在Swing组件上(它不需要那么精确,只是在某种程度上正确显示各种陆地)并且还绘制了额外的点。该地图的顶部,并让他们坚持到各种纬度/经度坐标。

I'm totally open to switching libraries, however I really haven't found a library that can take care of drawing a world map, particularly onto a Swing component (it doesn't need to be that accurate, just show the various landmasses somewhat correctly) and also plotting additional points on top of that map and having them "stick" to various latitude/longitude coordinates.

我看过谷歌地球和NASA WorldWind,但它们对我的目的非常重(我不需要任何详细或准确的内容)并且似乎不容易离线使用并将世界图像视图集成到现有应用程序中。

I have looked at Google Earth and NASA WorldWind, however they are awfully heavy for my purposes (I don't need anything that detailed or accurate) and it doesn't seem that easy to allow for offline use and integrate the world image view into an existing application.

建议或想法?

推荐答案

您可以查看www.osgeo.org Java堆栈的其他组件。其中一个是geotools:
http://geotools.codehaus.org/

You might take a look at other components of the www.osgeo.org Java stack. One of them is geotools: http://geotools.codehaus.org/

他们也正在开发创建GUI:
http://geotools.codehaus.org/GUI+Architecture

they is also development going on to create a GUI: http://geotools.codehaus.org/GUI+Architecture

这篇关于使用Java和任何外部库,如何将纬度/经度点绘制到地球的图形表示中?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆