[GRASS-user] Buffering large grid maps

Glynn Clements glynn at gclements.plus.com
Tue Jul 22 07:52:30 EDT 2008


Milton Cezar Ribeiro wrote:

> Hi Glynn Clements,
> 
> Thanks for your reply. In fact I need to generate a (uncontroled) distance
> map from all my values=1.
> I confess that I don´t understood how r.grow will help me on this task.
> I need to build a for looping and grow and grow many times the new generated
> map?
> Or is there a a way of simple generate a distance map on one command?

"r.grow ... in=1 out=2" has the same effect as r.buffer with a single
distance, except that r.grow's radius= option is measured in cells
while r.buffer's distance= option is measured in physical units (e.g. 
metres).

You can get the same effect as r.buffer with multiple distances by
running r.grow once for each distance value, then overlaying the
results, from largest to smallest buffer size.

r.grow will be quite a bit slower, particularly for large distances,
but it doesn't require that the map fits into memory.

Alternatively, you could reduce the resolution, so that the map fits
into memory. Or you could run r.buffer on smaller sections of the
data, then merge the results with "r.series method=minimum".

-- 
Glynn Clements <glynn at gclements.plus.com>


More information about the grass-user mailing list