[Gdal-dev] GDAL error exporting grass raster to Gtiff
Dylan Beaudette
dylan.beaudette at gmail.com
Wed Nov 8 12:08:37 EST 2006
On Wednesday 08 November 2006 02:38, Yves Jacolin wrote:
> Le Mardi 7 Novembre 2006 21:07, Markus Neteler a écrit :
> > On Tue, Nov 07, 2006 at 12:42:11PM +0100, Yves Jacolin wrote:
> > ...
> >
> > > Is it correct ? Is it normal that gdal-grass doesn't appear ?
> >
> > Ah, yes, I think that it doesn't appear there since it is loaded
> > only on demand.
> >
> > > Y.
> > > PS : is it the right list to post this problem ?
> >
> > Hope so :-)
> >
> > Please have a look at
> > http://grass.gdf-hannover.de/wiki/Compile_and_install_GRASS_and_QGIS_with
> >_G DAL/OGR_Plugin#Troubleshooting
> >
> > Markus
>
> Hi,
>
> All seems fine! BTW I found another way to export my raster. Thank you very
> much for your help.
>
> Y.
Hi,
I have encountered some problems in creating an ESRI-friendly geotiff using
r.out.gdal directly. Fortunately I was able to use the following to get a
workable file:
# export to AAIgrid with nodata set to -9999
r.out.arc in=ca_90m_dem_meters out=ca_90m
# convert to geotiff with gdal_translate
gdal_translate -a_srs "+proj=aea +x_0=0.0 +y_0=0 +lon_0=-96 +lat_0=40.0
+lat_1=20 +lat_2=60.0 +datum=NAD83 +units=m" \
-a_nodata -9999 \
-co INTERLEAVE=PIXEL \
-co TFW=YES \
-co COMPRESS=DEFLATE \
ca_90m ca_90m.tif
I wonder if there is a better way? The main problem lies in the fact that
r.out.gdal encodes GRASS NULL values as NaN, which doesn't seem to carry over
to other programs...
Cheers,
--
Dylan Beaudette
Soils and Biogeochemistry Graduate Group
University of California at Davis
530.754.7341
More information about the Gdal-dev
mailing list