[Gdal-dev] GDAL raster output to GE Add -> Image overlay ...

Roger Bivand Roger.Bivand at nhh.no
Sun Nov 26 05:45:16 EST 2006


On Sat, 25 Nov 2006, Roger Bivand wrote:

> Hi,
> 
> Does anyone have any experience of outputting rasters for adding as image
> overlays to Google Earth? I have success with a Byte type GTiff (just
> integers in the 0-255 range), but have to type the bounding box into the
> form directly. 
> 
> Attempts to set an alpha channel crash GE when reading the file (it does
> say alpha only with PNG, so I'm not surprised - my GE 4.0.2413 (beta) on
> RHEL). I have not tried an RGB GTiff yet. Because PNG is a CreateCopy, and
> we've used Create in writing from R, I haven't tried that route yet. The
> target is to provide gridded interpolations in a readily distributable
> format for users without access to GIS.

Doing:

gdal_translate -of PNG grey_a.tif grey_a.png

(http://spatial.nhh.no/misc/grey_a.png)

on the grey/alpha GTiff that crashed GE gives a usable PNG that GE 
displays without problems, displaying only the study area for which 
interpolation was made. The remaining question is then whether GE can read 
any format of world file or other metadata for a PNG to fix the bounding 
box without manual entry - any experience? I guess that an RGB+A GTiff 
will gdal_translate to PNG successfully, will check.

Roger

> 
> Thanks for any insights,
> 
> Roger
> 
> PS. Trial single band file at:
> 
> http://spatial.nhh.no/misc/grey.tif
> 
> is IDW of Meuse bank zinc ppm soil pollution, with bbox:
> 
>        min     max
> s1  5.7209  5.7649
> s2 50.9555 50.9879
> 
> 
> 

-- 
Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Helleveien 30, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43
e-mail: Roger.Bivand at nhh.no





More information about the Gdal-dev mailing list