Trying to convert lines to polygons

Michel Wurtz - LTE mw at engees.u-strasbg.fr
Fri Mar 5 11:44:06 EST 1999


Juan Bañuls wrote:
> 
> >The areas you create are not labelled (means that v.to.rast will give
> >you an empty file).  Snapping doesn't help.  Labelling is done via the
> >dig_att file : an entry for each area or line to be labelled made as
> >following for an area :
> >
> >A xxxxxx yyyyyy nn
> >
> >A means area (L for line), xxxxx and yyyyyy are the coordinates of the
> >label point (inside the area), and nn is the area number (> 0).
[...]
> >If you have some labels in dxf, you can import them in the dig_att file
> >with respect to the format showed above (v.digit is sometimes boring
>
> Well, in order to export the map into a raster format it would be a good
> solution, but I want to get the areas in the vector format and export
> them into a shape file. It doen't matter if the dbf file is empty, I
> only want the map.
> In the other hand, GRASS detect the lines not owned by areas (in v.digit
> I can see these opened lines, option "o" in the Toolbox), but I cannot
> create new areas from v.digit. I've tried to label all the lines of a
> not detected area and after that I don't know how to make GRASS to
> detect the polygon (v.support doesn't recognize it).
> Besides, it would be very boring to create all the missing areas from
> v.digit because I am working with big maps...

If you have only one attribute (number, not string) for each poly,
this number can be the third figure in the dig_att file, and the
two first the coordinates of a point inside the poly.
After cleaning with v.digit, you have to run v.support and verify
that there is no attribute left (v.support doesn't modify dig_att)

After that, you can transform through v.to.rast OR export in shape
format... but why not directly import dxf ? or change from line
to poly in the final software ?

-- 
Michel Wurtz    ENGEES - Laboratoire Territoires & Environnement
                1, quai Koch - BP 1039, F-67070 STRASBOURG cedex
                Tel: +33 03.88.24.82.45  Fax: +33 03.88.37.04.97



More information about the grass-user mailing list