One problem when exporting a SketchUp model that contains images as textures to Google Earth is file size. You do not want to have a building model that weighs in at more than 500kB. A 1 MB file may be justified for a very complex building, but anything beyond that will a) load slowly (remember that these models are streamed over your internet connection) and will b) reduce the chances that Google will ever include it in the 3D Building layer in GE. As a result, we have to put our models on a diet. Pardon the pun, but we are after anorexic models here.
The best way to create lightweight models is to start with small texture images in the first place. Before you import images as textures, resize them and save them with these specs:
- Longest image dimension: approx. 800 px or less, depending on detail. Don’t include too much detail.
- JPG file compression: reduce to 50% quality or even less. Check that quality is still acceptable afterwards.
After placing these images, the SketchUp file size typically becomes just a little larger than the sum of all included images. You can then get a good feeling of how large the file will be if you highlight all image texture files and check their combined size:
So what do you do if you or someone else already placed way too large images into a building’s model. You could re-texturize the entire model (export images, resize and re-import). That sounds painful. Here are two methods that will help you solve this problem.
1. 3DS Export/Import Workaround
When you export a SketchUp file to the 3DS file format (go to File > Export > 3D Model… and choose 3DS from the drop-down menu) you’ll find a 3DS-file, an MTL file and a bunch of image files in the export location. Those images are your (adjusted and cropped!) textures. All you need to do now is resize and re-save (with the lower file quality setting) these images and re-import the 3DS model into SketchUp.
Make sure you don’t rename any of the images in this process. Also, the aspect ratios should not be changed. In any case, look for a batch conversion feature in your image editing program (or write a script to do that) to make your life easier.
2. Open the KMZ File Directly
When you export a SketchUp model for Google Earth, a KMZ-file is created. This file is actually just a ZIPped file with a different extension. Rename the file to a .ZIP extension and look inside (using either Explorer or one of the ZIP-compression tools). Inside you’ll find something like this:
The KML-file contains the georeferenced geometry in an XML format, the textures.dat file is just a list of all the textures and their locations and the files folder contains all of your texture image files. You can now unzip the image files, resize and reduce them and then copy them right back into the ZIP file. After renaming the Zip file back to KMZ, you will see that the Google Earth model has now drastically reduced in size.
That’s it! Have fun making models for Google Earth. Oh, and in case you are competing for this year’s Model Your Campus Competition – make way for the fantastic UMass collection!
P.S. You may need SketchUp Pro for 3DS export. If the free version doesn’t have this capability, download the demo version of Pro and install it parallel to the free version. Then just use it for file exports.
P.P.S. If you want to convert a bunch of SketchUp or KMZ models to untextured building shapes (“clay presentation”), just delete the image files in the 3DS or KMZ file before re-importing or loading into GE.