Shape object

Frank Warmerdam warmerdam at POBOX.COM
Thu Aug 9 04:46:29 PDT 2007


Jeppe Lund Andersen wrote:
> Hello all
>  
> Iam trying to get the x and y out of a shape object
> the shape object has 3 holes in it
> and when I loop through it I cannot see if it is a hole or not.
>  
> I could say that the first one is the shape and the rest is the holes, 
> but that will not work if I have a multipolygon with holes
> is there any way to see if the shape I have is a hole.

Jeppe,

MapServer does not keen to keep track of which rings are outer and
which are inner (holes) because the scanline rasterizer of GD doesn't
care.  Or you could say the rasterizer implicitly figures it out as
it goes.

So, I'm afraid you are out of luck to be sure what rings are what in a
polygon shapeObj.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | President OSGeo, http://osgeo.org



More information about the MapServer-users mailing list