开发者

Algorithm - How to build a polygon around a polyline

开发者 https://www.devze.com 2023-02-28 18:15 出处:网络
I am building a web site using googles Map API. However, as I am on a shared server, I do not have access to a database with spatial extensions.

I am building a web site using googles Map API. However, as I am on a shared server, I do not have access to a database with spatial extensions.

Given an itinerary, which is nothing more than a series of line segments, I need to build a polygon at a given distance. For example 10km either side of the itinerary.

This is the classic buffering request, which I have seen as being referenced as the " Minkowski sum " al开发者_运维技巧gorithm. After having searched, I have not found a working example of an implementation.

Can anyone help me implement this ... please ?


You should take a look at CGAL. This library contains (among a lot of other things) an Open Source Minkowski sum implementation, which you could analyse. See here

0

精彩评论

暂无评论...
验证码 换一张
取 消