I have 12 images that represent weather conditions at day 1 through day 12. I am using gdal2tiles to produce map tiles from each of these images. gdal2tiles also produces a KML file that can be used in Google Earth to display the tiles.

However, I want to create an animated layer out of all 12 images. Google Earth seems to support animation in KML files (see https://developers.google.com/kml/documentation/time#example2). Are there any tools to create an animated ground overlay KML file such as this? Is gdal2tiles capable of it?

Thanks a lot. - Mike

  • My best suggestion would be to follow this commenter's advice: "gis.stackexchange.com/questions/72550/…" and attempt "to merge the multiple, static KML files you currently have into one KML file with multiple TimeStamp-ed Placemarks". As gdal2tiles produces the KML file, it would appear that that would be the tool to use. Sorry I can't offer much more than this. Good luck!
    – TheLastGIS
    Commented Oct 14, 2013 at 2:50

1 Answer 1


A wonderful tool to create an animated ground overlays KML file is simplekml, "a python package which enables you to generate KML with as little effort as possible."

The following is a quick and dirty reproduction of the TimeSpan Example you mentioned before using simplekml:

import simplekml
kml = simplekml.Kml()

ground1 = kml.newgroundoverlay(name='Blue Marble - Jan')
ground1.icon.href = 'http://mw1.google.com/mw-earth-vectordb/kml-samples/bmng12/files/BMNG-Jan.jpg'
ground1.gxlatlonquad.coords = [(-180,-90),(180,-90),(180,90),(-180,90)]
ground1.timespan.begin = "2004-01-01"
ground1.timespan.end = "2004-01-31"

ground2 = kml.newgroundoverlay(name='Blue Marble - Feb')
ground2.icon.href = 'http://mw1.google.com/mw-earth-vectordb/kml-samples/bmng12/files/BMNG-Feb.jpg'
ground2.gxlatlonquad.coords = [(-180,-90),(180,-90),(180,90),(-180,90)]
ground2.timespan.begin = "2004-02-01"
ground2.timespan.end = "2004-02-29"

ground3 = kml.newgroundoverlay(name='Blue Marble - Mar')
ground3.icon.href = 'http://mw1.google.com/mw-earth-vectordb/kml-samples/bmng12/files/BMNG-Mar.jpg'
ground3.gxlatlonquad.coords = [(-180,-90),(180,-90),(180,90),(-180,90)]
ground3.timespan.begin = "2004-03-01"
ground3.timespan.end = "2004-03-31"

# ...and so on with the other months


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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