Michael Bedward ha scritto:
> Hello,
> 
>> I'd like to fill the polygons with multiple colors such that adjacent
>> polygons don't have the same color. How can I do this ?
> 
> Easiest answer - if number of polygons is small make them all
> different colors :)
> 
> General answer...
> Theoretically you only need four colors to achieve what you want with any 
> map...
> 
> http://en.wikipedia.org/wiki/Four_color_theorem
> 
> But it's actually better to have five colors because there is a much
> faster algorithm for this...
> 
> http://en.wikipedia.org/wiki/Five_color_theorem#Linear_time_five-coloring_algorithm
> 
> I'd be interested to hear if anyone on the list has already got an
> implementation of this. Perhaps some clever bit of GeoServer ?

Nope, we don't have anything like that. As far as I can see this would
have to be done in pre-processing anyways, first a full scan of the
data and then assign the colors?

A tool could be used to load the data, build a connectivity map,
assign the colors, and generate a SLD using FID filters to assign
the 5 colors to the different polygons.

Cheers
Andrea



-- 
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.

------------------------------------------------------------------------------

_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to