Exported File Is Too Big
There are three types of data in exported scene files:
- Scene geometry - all the objects, vertices, triangles etc;
- Artwork - images, textures, watermarks, environment maps etc;
- Koru engine - if exported into a single HTML file.
Koru engine itself is relatively small (below 100 Kb) and is not included to the exported scene unless you export it to a single HTML file, so it shouldn’t affect the loading time at all.
Another thing that is good to remember is that exporting scenes to single self-contained HTML file increases its size to about 30% as Koru has to convert scene binary data to HTML-compatible text that takes more space. If loading speed is an issue, consider using server-based export instead.
Reducing Artwork Size
Koru does a good job of selecting export artwork compression type to make the ouptut file smaller. You can help it by limiting the textures resolution and white-listing most important textures.
You may also consider pre-processing and downscaling textures before loading them to Koru to have more control on the artwork size.
Reducing Geometry Size
It might be a good idea to optimize some of your shapes using mesh optimizing tool. It can save you a lot of bytes if some of your shapes are really heavy. Make sure you checked the texture mapping of meshes after optimization.
What To Optimize?
To estimate the artwork/geometry balance in exported scene you can export it for Facebook. At the very last page of the export wizard you will get a breakdown of the exported scene. It doesn’t 100% match the server/cloud/disk export options, but it will show what takes the most in your scene.
Have a look at other possible problems you can have with Koru: