blankblank blank




Animated GIFs In Google Earth



Google Earth supports GIF files as image overlays, with or without transparency, but it doesn’t directly support animated GIFs. However, by “disassembling” the animated GIF into the individual frames, and then assigning each of those frames a time stamp in a KML file, you can re-create the animation effect using Google Earth’s time animation feature.

Once you have a GIF animation, one you’ve either downloaded or created with a free GIF animation program like Beneton Movie GIF, you need to break the GIF animation down into its individual frames. There’s a free utility called GIFSplitter that will do that for you, splitting the image into all its frames as BMP files if you check the “Auto fill” box:

It’s usually best to convert all of the individual frames back to GIF format, using your favorite graphics editor or IrfanView (which has a Batch Conversion capability to speed things up). You can also add transparency to the GIFs at this stage. But this isn’t required; you can create animations with the BMP images, or use a similar process to animate sets of JPG, PNG, or TIF images as well.

Next, define the geographic position extents for the GIF animation. Open Google Earth, create a folder, and then add the first of the animation frames as an overlay. Position it where you want it; if you re-size it, and want to maintain the original aspect ratio, keep the shift key depressed during resizing, otherwise the resizing may stretch or compress the image in one or both dimensions. Once you have it sized and positioned where you want it, save the folder with the one overlay as a KML file like this one:

<?xml version=”1.0″ encoding=”UTF-8″?>
<kml xmlns=”http://earth.google.com/kml/2.1″>
<Folder>
<name>Animation</name>
<open>1</open>

<GroundOverlay>
<name>Untitled Image Overlay</name>
<Icon>
<href>C:/Captures/penguinsdancing.gif.ifl/IMG00000.gif</href>
<viewBoundScale>0.75</viewBoundScale>
</Icon>
<LatLonBox>
<north>-71.54193350154206</north>
<south>-71.57016090675403</south>
<east>-12.07503263159531</east>
<west>-12.21545153576837</west>
<rotation>54.53226789942224</rotation>
</LatLonBox>
</GroundOverlay>

</Folder>
</kml>

Now you need to add both a GroundOverlay section for every image file in the animation, and also assign a timespan for every image so that you can animate it. In the example below, I’m assigning an year to every animation frame, with the time extent for every frame running from January 1 to December 31 for every year:

<?xml version=”1.0″ encoding=”UTF-8″?>
<kml xmlns=”http://earth.google.com/kml/2.1″>
<Folder>
<name>Animation</name>
<open>1</open>
<GroundOverlay>
<name>Untitled Image Overlay</name>
<TimeSpan>
<begin>2000-01-01</begin>
<end>2000-12-31</end>
</TimeSpan>
<Icon>
<href>C:/Captures/penguinsdancing.gif.ifl/IMG00000.gif</href>
<viewBoundScale>0.75</viewBoundScale>
</Icon>
<LatLonBox>
<north>-71.54193350154206</north>
<south>-71.57016090675403</south>
<east>-12.07503263159531</east>
<west>-12.21545153576837</west>
<rotation>54.53226789942224</rotation>
</LatLonBox>
</GroundOverlay>

<GroundOverlay>
<name>Untitled Image Overlay</name>
<TimeSpan>
<begin>2001-01-01</begin>
<end>2001-12-31</end>
</TimeSpan>
<Icon>
<href>C:/Captures/penguinsdancing.gif.ifl/IMG00001.gif</href>
<viewBoundScale>0.75</viewBoundScale>
</Icon>
<LatLonBox>
<north>-71.54193350154206</north>
<south>-71.57016090675403</south>
<east>-12.07503263159531</east>
<west>-12.21545153576837</west>
<rotation>54.53226789942224</rotation>
</LatLonBox>
</GroundOverlay>
<GroundOverlay>
<name>Untitled Image Overlay</name>
<TimeSpan>
<begin>2002-01-01</begin>
<end>2002-12-31</end>
</TimeSpan>
<Icon>
<href>C:/Captures/penguinsdancing.gif.ifl/IMG00002.gif</href>
<viewBoundScale>0.75</viewBoundScale>
</Icon>
<LatLonBox>
<north>-71.54193350154206</north>
<south>-71.57016090675403</south>
<east>-12.07503263159531</east>
<west>-12.21545153576837</west>
<rotation>54.53226789942224</rotation>
</LatLonBox>
</GroundOverlay>
<GroundOverlay>
<name>Untitled Image Overlay</name>
<TimeSpan>
<begin>2003-01-01</begin>
<end>2003-12-31</end>
</TimeSpan>
<Icon>
<href>C:/Captures/penguinsdancing.gif.ifl/IMG00003.gif</href>
<viewBoundScale>0.75</viewBoundScale>
</Icon>
<LatLonBox>
<north>-71.54193350154206</north>
<south>-71.57016090675403</south>
<east>-12.07503263159531</east>
<west>-12.21545153576837</west>
<rotation>54.53226789942224</rotation>
</LatLonBox>
</GroundOverlay>

And so on until the final animation frame …

<GroundOverlay>
<name>Untitled Image Overlay</name>
<TimeSpan>
<begin>2024-01-01</begin>
<end>2024-12-31</end>
</TimeSpan>
<Icon>
<href>C:/Captures/penguinsdancing.gif.ifl/IMG00024.gif</href>
<viewBoundScale>0.75</viewBoundScale>
</Icon>
<LatLonBox>
<north>-71.54193350154206</north>
<south>-71.57016090675403</south>
<east>-12.07503263159531</east>
<west>-12.21545153576837</west>
<rotation>54.53226789942224</rotation>
</LatLonBox>
</GroundOverlay>
</Folder>
</kml>

Note: Unlike HTML, case counts in KML (as I found out to my frustration), so make sure you enter “TimeSpan”, not “timespan”. Once you’re done, open the edited KML file in Google Earth, and you should see the animation control at the top:

Clicking the play button at the right should play the animation, and you can set the animation speed and repeat mode (once, bounce or wrap) by clicking on the check at the left. You should also set the time start and stop span control to be the same (as they are above - the control should look like the one tagged by “AUG 2023″), otherwise you may see multiple animation frames at the same time. If you’re happy with the animation, save the entire folder as a KMZ file that will contain all of the animation graphics in embedded form. You can download the goofy sample animation I created above at this link.

Other posts in the Google Earth Data Tools series

  1. KML Editors
  2. Diagramming In Google Maps And Google Earth With Smoot
  3. Plotting Data In Google Earth Using GE-Graph
  4. Drawing Grids, Paths And Polygons In Google Earth Using GE-Path
  5. Online Google Earth Utilities For Buffering And Area Calculations
  6. Easy Display Of Thematic Data In Google Maps And Google Earth
  7. Using GIF/PNG Transparency In Displaying Raster Graphics In Google Earth
  8. Adding Vector Graphic Objects To Google Earth
  9. Animated GIFs In Google Earth
  10. Creating A Network KML Link To A Google Spreadsheet
  11. LIDAR Tools
  12. EarthPlot Software Tools For Google Earth
  13. Geographic Time Animations
  14. Convert TIGER Polygons To KML Files
  15. Putting Time Data Into A KML File
  16. Using The KML Time Embedder To Stamp Time Data Into A Google Earth File
  17. Using The KML Time Embedder, Concluded
  18. KML Time Embedder Improved With Hour-Minute-Second Ability
  19. Grid Creation And Path/Polygon Measurements: Two New Online KML Tools
  20. Google Earth PhotoOverlay Tool
  21. KML Random Placemark Generator
  22. Update For Online Google Earth Utilities
  23. KML Time Code Utility
  24. Screen Overlays In Google Earth
  25. The KML Screen Overlay Maker Utility
  26. KML Screen Overlay Maker Utility, Concluded
  27. KML Circle Generator
  28. Creating Google Earth Screen Overlays With EarthPaint
  29. Text Editor With KML Validation
  30. Online Spreadsheet To KML Converter
  31. Version 2.0 Of Google’s Online KML Spreadsheet Mapper Tool Released
  32. Creating Google Earth Ground Overlays From Georeferenced Images
  33. Google Earth Ground Overlays With GIF Transparency
  34. Creating "Transparent" Topo Map Overlays For Google Earth
  35. Using Google Earth Ground Overlays To Display Shapefile Data
  36. Converting 3D Objects Into Google Earth Format
  37. Thematic Mapping In Google Earth
  38. An Online KML Validator
  39. Modify A KML Polygon File With Excel Data
  40. US Nautical Chart Overlay For Google Earth
  41. Plot Google Analytics Geographic Data In Google Earth/Maps
  42. Placemark Creator For Google Earth


Subscribe to this blog's RSS feed

7 Responses to “Animated GIFs In Google Earth”


  1. 1 Leszek Pawlowicz

    Comments pulled in from the old site:

    Anonymous:

    I wanted to put an animated wind turbine on google earth. I was wondering if it is possible to animate it.
    In this case I don’t think you could use years as the frames, as you would rather want milli seconds. Also we are talking about vertical areas, not overlays. Do you think this could be done?

    My reply:

    Try this website:

    http://www.barnabu.co.uk/

    He’s been doing a lot of interesting animations, using both GIFs and SketchUp models. Check out in particular his London Eye animations, which isn’t too far away from what you want to do.

  2. 2 vukhiembk

    I add a GIF animation into Google Earth. How do it become a GIF animation on the Google Earth?

  3. 3 vukhiembk

    I was wondering if it was possible to overlay GIF animations on GE while that the the animation still runs its loops?

  4. 4 Leszek Pawlowicz

    Click on the checkmark at the left of the animation control, and set the mode to “Wrap” - it will then repeat the time animation over and over.

  5. 5 vukhiembk

    I add a placemark on GE and insert code html(Gif image)in description:

    When I click on the placemark then the GIF animation show but not runs its loops. Why?
    Can you help me so that the Gif animation runs its loops?

  6. 6 vukhiembk

    I add a placemark on GE and insert code html(Gif image)in description:
    “img src=”http://www12.24h.com.vn/upload/news/2007-09-24/T9_CauDo24-9.gif” alt=”" border=”0″ />”
    When I click on the placemark then the GIF animation show but not runs its loops. Why?
    Can you help me so that the Gif animation runs its loops?

  7. 7 Leszek Pawlowicz

    Google Earth does not support animated GIFs. You have to follow the procedure in my post to break it down into individual frames, and assign a time to the frame, so that it will run as a time animation.

Leave a Reply


Be sure to enter the "reCAPTCHA" below before submitting your comment.