[GRASS-user] making an area with existing lines

Markus Metz markus.metz.giswork at googlemail.com
Sun Mar 22 03:42:14 EDT 2009


Micha Silver wrote:
> hardinej wrote:
>
>> Hello,
>> I have two vector lines and I want to limit operations to the the 
>> area in
>> between these lines. I've had some ideas about how to do this, but I 
>> really
>> don't know how to. I don't know if this extra info would be useful, 
>> but here
>> it is: the lines are a road and a shoreline, the are roughly 
>> parallel, and
>> they do not cross. At first I thought maybe I could export them as 
>> ascii,
>> concatenate the list and import as an area, then convert to a raster 
>> that I
>> could use as a mask. I don't actually know if this would work because 
>> I was
>> having some troubles exporting the vector files, they were blank. But
>> anyway, if anyone could let me know what they think, that would be 
>> great. Thanks,
>> Eric   
> Depends on what operations you're planning. vector? or raster?
> For raster, I'd make the two parallel lines into a closed boundary 
> (using v.digit) and also digitize a centroid. THen I'd change the 
> vector area to a raster (v.to.rast type=area ...) and finally use that 
> raster as a mask. Now all raster operations will be limited to the 
> area between the two lines.
> If it's vector operations, I'd guess that you'll again want to create 
> a closed boundary with a centroid, and then, after running whatever 
> operations you have in mind, just do "v.overlay operator=and ..." to 
> get results again only in between the parallel lines.
Or run v.select first to select only the features falling into the newly 
created area. That may be faster, depending on the subsequent vector 
operation.



More information about the grass-user mailing list