Reduce file size

2,794 views
Skip to first unread message

MegCat

unread,
Mar 11, 2008, 9:30:40 AM3/11/08
to KML Developer Support - Advanced Support for KML
I have been given asked to find a way to reduce the size of some
already exiting KML files. The desire is to have the countries
sketched as detail as possible in Google Earth, but bandwidth is also
a concern. Is it possible to do this with out haveing the data set be
no more than a couple of MB in size? If so please provide guidance/
advice. Any an all input is greatly appreciated.
Thanks!

barryhunter [KML Guru]

unread,
Mar 11, 2008, 1:08:21 PM3/11/08
to KML Developer Support - Advanced Support for KML
Have you tried KMZ files? (They are just KML files inside a ZIP file)

If they are still too big,

1) you could try stripping whitespace out of the KML file (but
compressed not going to make a huge difference)

2) might be able to further decrease the size by using common Style's
for features, and possibly use BalloonStyle's to create templates for
info windows (if there is a repetitive 'layout' to each balloon. )

3) reduce the number of decimal places on coordinates, 6 dp should be
ample - accuracy of less than a foot.


but knowing which or other techniques are applicable would need to see
the data and files.

ManoM

unread,
Mar 11, 2008, 3:41:11 PM3/11/08
to KML Developer Support - Advanced Support for KML
I want to highlight Barry's #2 method. Many people who develop their
KML files using the Google Earth GUI tools end up having tons and tons
of <Style> elements. Consolidate them and you will substantially
reduce the size of your KML.

ManoM

MegCat

unread,
Mar 12, 2008, 11:22:09 AM3/12/08
to KML Developer Support - Advanced Support for KML
Thanks for your advice. Yes actually the files were in the KMZ format
and its those files which were too big, or at least larger than
desired. I will see if any of your suggestions below can be carried
out and hopefully this will work and solve the issue. Appreciate the
response.
> > Thanks!- Hide quoted text -
>
> - Show quoted text -
Reply all
Reply to author
Forward
0 new messages