1

I've got a kmz containing an unrefrenced jpg and a boundary box in kml.

ogrinfo is happy to report (filenames redacted):

INFO: Open of `Sim[...].kmz'
  using driver `LIBKML' successful.
1: Sim[...]

but, gdalinfo reports:

ERROR 4: `Sim[...].kmz' not recognised as a supported file format.

I've run these info commands with the generic gdal/ogr tools on 14.04 and a specially compiled 1.11.1 using this answer.

Is there a way, using some approximation of these tools (barring manual unzipping and georeferencing of the jpg), to export a geoTiff containing appropriately referenced raster data from this data?

2

In the past, I have used a script to unzip the kmz and extract the bounding box coordinates from the KML and used gdal_translate to georeference the image

The LatLonBox coordinates will map to the following values when using gdal_translate

ulx = west uly = north lrx = east lry = south

gdal_translate -a_ullr ulx uly lrx lry -a_srs EPSG:4326 input.jpg output.tif

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.