[GRASSLIST:9642] Re: filling basin in little steps

Hamish hamish_nospam at yahoo.com
Sun Dec 25 22:10:57 EST 2005


>> i have a dem in a fine resolution from a basin. is it possible in
>> grass to fill the basin in little steps (for example 10 centimeters)
>> to see the different flood-levels in the basin?
>>
>> maybe some internet-resources?
>>
>> greetings from the snowy austria

and from sunny New Zealand,

> I had similar problem last spring. Is solved it with r.mapcalc, but it
> was slooooooooooooow (24 - 48h for 3M cells).
>
> Now I wrote such GRASS module in C. Its almost ready for production
> use. In next days I was planing to clean up it from comments and send
> to GRASS devs for feedback/approval. It takes less than 1 min to
> process same maps (compare to 48 hours!).
> This module takes DEM and map with at least single cell under water
> level and water level in DEM units. It sets water depth to all cells
> below water level, which are connected to input cell. Result is lake
> depth map at given level. With simple shell script is possible to make
> such maps for different levels etc.
> I created movie how water level rises and fills teritory, but,
> unfortunatly, I dont have internet @home and dont have this avi with
> me. :(


Hi,

another approach if you are just after visualization:

load DEM surface into NVIZ,  then add a new surface, constant value set at 0.0
or whatever level you like. From the surface attributes list set the color
(perhaps to blue), and the transparency to about half way. Then either move the
surface up and down with the z-slider or by an exact amount with the set new
map constant dialog as above. You can just modify that (or make nviz script)
and do an image dump at each level. Combine the still images to an animation
with something like gifsicle for animated gifs or mng via imagemagick's
convert, fli with ppm2fli? (don't have my notes with me for those).

e.g., current coastline combined with ice age & tectonics lowered sea level to
get a rough idea what the coastline looked like when sea water first breached
into the inland lake,

http://bambi.otago.ac.nz/hamish/pics/sill_iceage_115m.jpg


Hamish



		
__________________________________________ 
Yahoo! DSL – Something to write home about. 
Just $16.99/mo. or less. 
dsl.yahoo.com 




More information about the grass-user mailing list