点,线和面与C / C ++球 [英] Points, Lines, and Polygons on Spheres with C/C++
问题描述
我的应用程序是重新地球(使用球就足够了)表面上present形状。这些可以是点,线和面。坐标应使用度或弧度(就像地理坐标)来定义。
My application is to represent shapes on the Earth's (using a sphere is sufficient) surface. Those can be points, lines, and polygons. Coordinates should be defined by using degrees or radians (just like geographic coordinates).
球体表面上两点之间线段应该位于其大圆。多边形应包括这样的行的集合。此外,我想执行设置 - 基本操作的像交, ,差,补中提到的形状。这些操作只需要点的输出集合。
A line segment between two points on the surface of sphere should lie on its great circle. Polygons should consist of a collection of the such lines. Furthermore, I would like to perform Set - Basic Operations like intersection, union, difference, complement on the shapes mentioned. These operations only need to output collections of points.
我试着去弄清楚使用CGAL的三维球面几何内核和< A HREF =http://doc.cgal.org/latest/Nef_S2/index.html相对=nofollow>关于Nef的多边形的2D布尔操作嵌入到球。其实,我已经与把一个行领域的问题。此外CGAL作品在欧氏空间,仍然给我留下必要的几何操作,放置在球体上大圆工作。
I tried to figure that out using CGAL's 3D Spherical Geometry Kernel and 2D Boolean Operations on Nef Polygons Embedded on the Sphere. Actually, I already had problems with putting a line on the sphere. Additionally CGAL works in the Euclidean Space, which still leaves me with the geometric operations necessary, to work with great circles placed on the sphere.
我的问题是,如果你能帮助我实现在CGAL提到的功能,或者,如果你能推荐,做了C / C ++的另一个库。非常感谢你!
My question is, if you can assist me in realizing the functionality mentioned in CGAL or if you can recommend another library for C/C++ that does that. Thank you very much!
推荐答案
如果你想要做像工会/路口等,那么你可以考虑从的 http://www.cs.man.ac.uk/~toby/alan/software/
If you want to do general polygon set operation like union/intersection etc., then you can look into General polygon clipper library from http://www.cs.man.ac.uk/~toby/alan/software/
这篇关于点,线和面与C / C ++球的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!