Re: change vector line direction
Maciek Sieczka <[email protected]>
| Newsgroups | gmane.comp.gis.freegis,gmane.comp.gis.grass.user |
|---|---|
| Message-ID | <[email protected]> |
On Thu, Apr 27, 2006 at 10:15:38PM +0200, Maciek Sieczka wrote: > Hi! > > I've been looking for a software which can change vector line > direction attribute. A thing that ArcInfo has been a long time > able to do... OK, I decided to do it myself and I think I have it working well enough to share it. Please find attached a final version of Bash + Awk script for flipping selected lines direction, and it's html man page. I wrote it for Grass 6.1, should be fine for 6.0 propably too. I'll appreciate any remarks. Would like to put in Grass WIKI soon if nobody minds. Best, Maciek -------------------- W polskim Internecie s? setki milion?w stron. My przekazujemy Tobie tylko najlepsze z nich! http://katalog.panoramainternetu.pl/ _______________________________________________ Freegis-list mailing list [email protected] https://intevation.de/mailman/listinfo/freegis-list
v.flip_16
(application/octet-stream, 5.7 KB) - not displayed
v.flip.html
(text/html, 2.3 KB)
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>v.flip</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <!-- <link rel="stylesheet" href="grassdocs.css" type="text/css"> --> </head> <body bgcolor="white"> <!-- <img src="grass.smlogo.gif" alt="GRASS logo"><hr align=center size=6 noshade> --> <h2>NAME</h2> <em><b>v.flip</b></em> - Flip direction of selected vector lines. <h2>SYNOPSIS</h2> <b>v.flip</b><br> <b>v.flip help</b><br> <b>v.flip</b> <b>input</b>=<em>name</em> <b>layer</b>=<em>integer</em> <b>cat</b>=<em>range[,range,...]</em> <b>output</b>=<em>name</em> <h3>Parameters:</h3> <DL> <DT><b>input</b>=<em>name</em></DT> <DD>Input vector name</DD> <DT><b>layer</b>=<em>integer</em></DT> <DD>Input's layer containing lines to be flipped</DD> <DT><b>cat</b>=<em>range[,<i>range</i>,...]</em></DT> <DD>Category ranges of lines to be flipped: e.g. 1,3-8,13</DD> <DT><b>output</b>=<em>name</em></DT> <DD>Output vector name</DD> </DL> <h2>DESCRIPTION</h2> <em>v.flip</em> is a Bash and Awk script. The <B>output</B> vector contains all lines that have a category in the given <B>layer</B> of the <B>input</B> vector. Lines specified in <B>cat</B> have their direction flipped. <P> The input layer number and category numbers are preserved in the output. If a datatable is attatched to the input vector's layer, it will be copied under the output vector's name and connected to the output vector, in the same database where the input layer's table is stored. <H2>NOTES</H2> Only lines with categories will be flipped. Use <B>v.category</B> to adjust category assignment first, if needed. <P> <EM>v.flip</EM> was tested only in <em>metric</em> Locations. I can't guarantee it will work properly in <em>latlong</em> or <em>unprojected xy</em> Locations, as <B>v.clean</B> is used internally with a fixed snapping distance of <B><em>0.0001</em></B> for connecting flipped and non-flipped lines. <h2>SEE ALSO</h2> <B>v.category</B><br> <B>v.clean</B> <h2>AUTHOR</h2> Maciej Sieczka, Wroclaw, Poland, 2006<br> Wroclaw University, Intitute of Plant Biology <!-- <p><i>Last changed: $Date: 2006/02/01 09:18:56 $</i> --> <HR> <!-- <P><a href="index.html">Main index</a> - <a href="vector.html">vector index</a> - <a href="full_index.html">Full index</a> --> </body> </html>