[GRASS-user] Re: Conversion of multiple rasters to PNG files

Mortsde alex.mortsde at gmail.com
Wed Apr 13 13:21:31 EDT 2011


Daniel,

Thanks for that write up. I just wanted to ask what the purpose of the /tmp/
line was. It seems like the conversion ran through just fine, but I don't
see any of the files saved to a specific place. Is the "/tmp/" listing the
folder directory where the files are written?



daniel mcinerney-2 wrote:
> 
> Hi,
> you could use the following bash for loop as a
> basis for what you want to do:
> 
>  for file in `g.mlist rast pattern=searchpattern*`;
>      do r.out.png input=$file output="/tmp/"$file".png";
>  done
> 
> Regards,
> Daniel
> 
> On Tue, Apr 12, 2011 at 5:10 AM, Mortsde <alex.mortsde at gmail.com>
> wrote:
> 
>> Hi Community,
>>
>> I'm relatively new to GRASS/unix style commands and was wondering if
>> anyone
>> had a quick PERL script that could convert LOTS of raster maps to PNG
>> files
>> without the repetition of going through one by one. I'm not much of a
>> programmer otherwise I'd write some kind of loop and have a go.  The
>> general
>> form of my rasters is already in a "Name_$Date" style format so I think
>> this
>> should be pretty easy? I'm attempting to make video files that illustrate
>> soil saturation with time. I have about 10 years (daily) of soil moisture
>> that I'm looking to animate so it's a digestible amount of information.
>>
>> Thanks for reading/advice!
>>
>>
>>
>> --
>> View this message in context:
>> http://osgeo-org.1803224.n2.nabble.com/Conversion-of-multiple-rasters-to-PNG-files-tp6263692p6263692.html
>> Sent from the Grass - Users mailing list archive at Nabble.com.
>> _______________________________________________
>> grass-user mailing list
>> grass-user at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/grass-user
>>
> 
> _______________________________________________
> grass-user mailing list
> grass-user at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user
> 


--
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Conversion-of-multiple-rasters-to-PNG-files-tp6263692p6269876.html
Sent from the Grass - Users mailing list archive at Nabble.com.


More information about the grass-user mailing list