
-->
This FAQ page is actually written for Sandy 1.1 and 1.2, but there might be some useful information if your Sandy version is higher.
There are many, many factors that impact performance. I've categorized them in a way that should allow you to experiment with different options. The best performance is often achieved by multiple small optimizations, and there is often a tradeoff between quality and speed (see quality). Remember, if you improve 10 small things, the overall impact can be dramatic. It is often possible to speed things up 100% or more.
Things in the environment that affect performance but may be beyond the developer's control include:
Flash Player version
Browser version - Firefox,
IE, Safari, etc.
Computer's memory, graphics card, CPU speed
Internet connection speed
Other applications running simultaneously
Operating system - Mac, Windows, Linux - various flavors
Whether it is running locally or remotely.
Whether it is running in authoring mode (Flash's debug mode is extremely slow), a browser, projector, or third-party EXE such as SWF Studio.
If your application is running slowly, test it on another machine. In the end, you may need to scale back your application or specify a beefier minimum playback platform. Or you might require a later version of Flash Player.
Things that affect the rendering speed of individual models:
Skin, skin, skin! - The skin type can have a dramatic effect on performance. Try using a SimpleColorSkin or SimpleLineSkin for speed comparisons.
Shading - turn off shading with Skin.setLightingEnable(false) in Sandy 1.1 (I'm not sure if that is the same in 1.2)
Alpha/transparency - set alpha to 100, which renders fastest.
Flash 8 vs Flash 7 - publish your project in Flash 8, which has some faster rendering options - I haven't tested BitmapScreen mode in 1.1 (and I think it is buggy) but using Flash 8's bitmap optimization should be faster.
Number of polygons or faces for an object. A sphere renders much more slowly than a pyramid. Try reducing the quality setting, such as for a cylinder, to reduce the number of polygons.
Avoid complex models, such as those imported from ASE files; reduce/simplify the model if possible.
Backface culling - turn on backface culling for better performance (set Object3D.enableBackFaceCulling = true). See also Object3D.swapCulling();
Use smaller images for your TextureSkins.
Turn off animation of MovieSkins.
Avoid VideoSkins.
Does turning on/off Light3D affect performance? Probably.
Things that affect the overall performance of the world:
The rendering engine. Are you using Sandy 1.1? Maybe some of the optimizations in Sandy 1.2 will help.
Consider reducing the number of objects in the world. Add objects one at a time to see when performance degrades. See also section above regarding simplifying individual objects.
There are ways to combine transforms for better performance. For example, instead of nesting three transforms, you can calculate one matrix manually.
Consider reducing the depth of the object hierarchy. For example, if some objects don't move or rotate independently, they don't have to exist within their own transform group.
The size of the world and how fast things are moving affect the redraw area. Test it with a smaller world or less movement.
Increase the frame rate to increase the number of renderEvents being sent per second. Keep your render handler short/fast.
Reduce ther buttons and elements in Flash outside your 3D Sandy world. Don't forget to minimize the “chrome” around your viewport.
Loading external content can be slow, especially if it is from a different server or large media.
Reduce other heavy/complex ActionScript code or eliminate poor programming techniques.
If things slow down over time, check for memory leaks. Be sure to dispose of things you don't need any more.
Loading images dynamically at runtime can quickly consume a lot of memory - use smaller textures.
At authoring time, avoid a lot of trace() statements or updating text fields dynamically as these consume performance. Update them as infrequently as possible (i.e. only when something changes rather than constantly).
Use an optimizing compiler such as MTASC but beware as it might introduce other problems (test carefully).
Employ generic Flash optimization techniques as above.
