[GRASS5] Nested vector islands, and incorrect left/right poly id's for island edges...

Radim Blazek radim.blazek at wo.cz
Wed Jan 23 00:03:56 EST 2002


On Tuesday 22 January 2002 08:32, Eric G. Miller wrote:
> It appears that GRASS doesn't write correct information for
> left/right adjaceny for edges of areas nested more than
> one polygon deep.  That is: If polygon 1, contains polygon
> 2, and polygon 2 contains polygon 3, the lines comprising
> polygon 3 will have polygon 1 written as the adjacent area
> for either left or right, when I would think it should be
> polygon 2.

We have to distinguish areas and isles.
Are you sure that polygon1 is area1 and is not island1?

>
> I was trying to work up a way to do the following:
>
>   Given an area with N islands/holes.  Create a set of
>   interior boundaries such that islands/holes that
>   share one or more edges are combined into a single
>   boundary (with interior edges being dropped).
>
> I tried to write a little program that iterated through
> areas, and their islands, reporting the lines for all
> and the reported line left/right indices.  That's when
> I discovered, I was getting islands where none of the
> edges reported being adjacent to their immediate parent.

For boundary inside other area (-island)  is saved instead of (+area) for 
outside area side. Sorry, you probably know that all. 

> I guess, next I'll try using nodes instead of edges.  If
> anyone familiar with the guts of the vector libraries
> (Radim, David ?) wants to point me in the right direction,
> I'd appreciate it...
>
> Attached:  area_report.c & Gmakefile

You may be interested in grass51. I have v.build option=dump
( Vect_dump() ) and d.vect display=topo,dir (topo - topology
numbers, dir - direction of lines - arrow). I hope to commit
this week.

Radim






More information about the grass-dev mailing list