Complete.Org: Mailing Lists: Archives: freeciv-dev: April 2002:
[Freeciv-Dev] Freeciv borders
Home

[Freeciv-Dev] Freeciv borders

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Freeciv borders
From: "Michael Rouse" <mrouse@xxxxxxxxxx>
Date: Mon, 8 Apr 2002 06:36:13 -0700

One of the common Freeciv suggestions (in fact, it's on the freeciv.org Suggestions/Ideas page) is for national borders, something like what was implimented in Alpha Centauri or Civ III. IANAP (I Am Not A Programmer), but there is an excellent way to calculate such borders: Voronoi polygons.
 
To give an idea how they would work, look at the following site: http://www.cs.cornell.edu/Info/People/chew/Delaunay.html Imagine every point you click in the Java window is a city. The Voronoi lines show the "national border" between cities. If we also take into account each cities area of influence, we can use the square root of the city size to adjust these Voronoi borders. Color each polygon with the color of the civilization on the general map and draw the borders. The algorithm can be adjusted to work on a plane, a cylinder, or a sphere, depending on the style of map you prefer.
 
Some background info and examples:
 
Michael Rouse

[Prev in Thread] Current Thread [Next in Thread]