[GRASS-user] convert vector line topology to area topology

Markus Neteler neteler at itc.it
Fri Jul 7 18:16:30 EDT 2006


On Fri, Jul 07, 2006 at 08:24:55PM +0200, Maciek Sieczka wrote:
> On Fri, 07 Jul 2006 14:37:06 +0200
> Nicolas Devaux <devaux at ensam.inra.fr> wrote:
> 
> > Hi, I start to use Grass, and I'm wondering if I'm not doing wrong, 
> > trying to apply ArcInfo 7 concepts to Grass vector topology.
> > 
> > Is it possible to change a vector line topology map to a new vector
> > area topology map?
> > 
> > I explain : I imported a raster map showing fields boundaries. I want
> > to convert this map into vector information showing fields as areas.
> > Before doing that, I would like to work on line geometry in order to
> > enhance final quality information (close interrupted boundaries,
> > erase dangle nodes...).

Shouldn't r.to.vect feature=are give you closed polygons?

> > I use r.to.vect with line option and do all cleaning operations
> > needed. But after all I can't reach area topology (using v.build or
> > v.clean). If I use at the beginning r.to.vect with area option,
> > unclosed fields boundaries are not converted....
> > With Arcinfo, I used to import at first line information, and it was 
> > possible after to reach polygon topology using "build polygon"
> > command. How can I manage the same problem with Grass?
> 
> Grass "areas"="boundary"+"centroid". Atrributes are attached to
> centroids, boundaries are usually attribute- and even category-less.
> 
> So the way to go might be:
> 
> Once you have your vector lines file cleaned as needed, remove it's
> datatable (v.db.droptable), delete categories from lines (v.category
> option=del) convert them into boundaries (v.type), add new datatable,
> which you will use for attributting centroids (v.db.addtable/db.execute
> +v.db.connect; the latter will let you understand Grass & DB issues
> better), digitize centroids,

Add categories/centroids to a vector map without categories

v.category in=wkt out=wktnew option=add


> one per each area (v.digit/QGIS) adding
> attributes manually (but I'm wondering whether v.what.rast wouldn't let
> you sample raster at centroids location instead of manally inputting
> attributes; or does it really support only points, as the manuall says
> - Anybody knows?).

To me it all sounds very complicated. Why not r.to.vect? Maybe I wa
reading the mail too fast :-)

Markus
 
> Maciek




More information about the grass-user mailing list