Hi Martin,

I think I see the cause.  It looks like sometimes, when a low priority
landclass is clipped against the already accumulated thin polys like roads
and steams, there could be a section that isn't removed (so only 1 region
is created when there should be 2).   Because the road region is still
added to the triangulation, and crosses the lower priority landclass, the
inside point only works for one of the regions.

I showed a bit how this looks in qgis on the forum. the picture shows that
a 'hole' contour actually separates the two sides of the road.  of course,
calc_points_inside only generates 1 point per non-hole contour, so only 1
resulting regions will have the material attribute.

Cleaning up the polys after clipping, and before triangulation seems to
help, but of course will not be 100% effective.

Pete

On Sat, Dec 17, 2011 at 9:41 PM, Martin Spott <martin.sp...@mgras.net>wrote:

> Hi Peter,
>
> Flightgear-commitlogs wrote:
>
> >          It doesn't crash, but sometimes, polygons lose their material.
>  I think fixing that
> >          should be easier than the endless massaging of data to keep
> good looking data.
>
> According to my/our (Ralf's and mine) experience loosing the material
> type was usually caused by the point-in-polygon droppping the centroid
> into the wrong polygon.
> The "terragear-cs" history contains a 'robust' point-in-polygon routine
> by Ralf Gerlich which might me worth investigating.  But there's a
> price to pay because the mentioned method might drop the centroid into
> areas of the polygon which later are getting eliminated without
> topologically correct handling of the centroid.  To put it into
> different words: If polygon massaging occurs in a topologically safe
> manner, there's a robust point-in-polygon available.
>
> Cheers,
>        Martin.
> --
>  Unix _IS_ user friendly - it's just selective about who its friends are !
> --------------------------------------------------------------------------
>
>
> ------------------------------------------------------------------------------
> Learn Windows Azure Live!  Tuesday, Dec 13, 2011
> Microsoft is holding a special Learn Windows Azure training event for
> developers. It will provide a great way to learn Windows Azure and what it
> provides. You can attend the event by watching it streamed LIVE online.
> Learn more at http://p.sf.net/sfu/ms-windowsazure
> _______________________________________________
> Flightgear-devel mailing list
> Flightgear-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/flightgear-devel
>
------------------------------------------------------------------------------
Learn Windows Azure Live!  Tuesday, Dec 13, 2011
Microsoft is holding a special Learn Windows Azure training event for 
developers. It will provide a great way to learn Windows Azure and what it 
provides. You can attend the event by watching it streamed LIVE online.  
Learn more at http://p.sf.net/sfu/ms-windowsazure
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to