Creating a model for use with Unity can be as simple or as complex as your project requires. The following sections detail everything you can do with SpeedTree that can benefit you inside of Unity.
Get started by creating your model at the highest level of detail using standard SpeedTree modeling. If you're new to SpeedTree you might want to start here or have a look at some of our introductory videos. Don't forget, it's often easier to edit an existing model than it is to start from scratch.
When you save a model several files are created. For example, if you were editing a model called “MyTree” these files are:
Wind animation in the SpeedTree modeler will carry over to Unity. The best way to get good settings for your model is to start with the Wind Wizard. This utility will apply wind settings based on your answers to a few simple questions. From there, select the “Fan” object and fine tune the wind behavior by editing the properties.
Of particular importance is the “Style” property in the “Presets” group. This property sets the wind complexity and has a direct impact on the vertex shader performance in Unity. Options are detailed below and are ordered from low quality/short shaders to high quality/longer shaders:
You can back the effect down in the Unity material editor, but you cannot go higher than what you set in the Modeler. It's often a good idea to tune the model using “Best” or “Palm” and lower the complexity in Unity if you need to optimize performance.
LODs are added by selecting the “Tree” generator and checking the “Enabled” property in the “Level of Detail” group. Set the number of LODs in this section as well. Each generator has an LOD group that controls how that part of the model degrades. Click here for more information on how to edit LODs on your model.
SpeedTree will compute a per-vertex ambient occlusion value for your model. These values can be hooked to Unity's material ambient occlusion system or to anything else in the material shader. Click here for more information on computing ambient occlusion.
A series of spheres and capsules can be added to the model to use as collision volumes in Unity. The quickest way to get started with collision objects is by selecting “Tools→Generate collision primitives…” and letting SpeedTree add some automatically. Click here for more information.