Legacy Documentation: Version 2018.2 (Go to current version)
Trees
Wind Zones
Other Versions

SpeedTree

SpeedTree AssetsAny media or data that can be used in your game or Project. An asset may come from a file created outside of Unity, such as a 3D model, an audio file or an image. You can also create some asset types in Unity, such as an Animator Controller, an Audio Mixer or a Render Texture. More info
See in Glossary
(.spm files saved by Unity version of SpeedTree Modeler) are recognized and imported by Unity just like other Assets. Ensure Textures are reachable in the Project folder, and Materials for each LODA system for building multiplayer capabilities for Unity games. It is built on top of the lower level transport real-time communication layer, and handles many of the common tasks that are required for multiplayer games. More info
See in Glossary
are generated automatically. There are import settings when you select .spm Assets for you to tweak the generated GameObjectThe fundamental object in Unity scenes, which can represent characters, props, scenery, cameras, waypoints, and more. A GameObject’s functionality is defined by the Components attached to it. More info
See in Glossary
and attached Materials. Materials are not generated again on reimporting, unless you hit the Generate Materials, or Apply & Generate Materials button. Therefore any customisations to the Materials can be preserved.

The SpeedTree importer in the end generates a PrefabAn asset type that allows you to store a GameObject complete with components and properties. The prefab acts as a template from which you can create new object instances in the scene. More info
See in Glossary
with LODGroup component configured. The Prefab can both be instantiated in a SceneA Scene contains the environments and menus of your game. Think of each unique Scene file as a unique level. In each Scene, you place your environments, obstacles, and decorations, essentially designing and building your game in pieces. More info
See in Glossary
as a common Prefab instance, or be selected as a tree prototype on the terrainThe landscape in your scene. A Terrain GameObject adds a large flat plane to your scene and you can use the Terrain’s Inspector window to create a detailed landscape. More info
See in Glossary
and be “painted” across it. Additionally, terrain accepts any GameObject with an LODGroup component as a tree prototype, and put no limitation on the meshThe main graphics primitive of Unity. Meshes make up a large part of your 3D worlds. Unity supports triangulated or Quadrangulated polygon meshes. Nurbs, Nurms, Subdiv surfaces must be converted to polygons. More info
See in Glossary
size or number of Materials being used (in contrast to the Tree Creator trees). But, be aware that SpeedTree trees usually use 3–4 different Materials, which results in a number of draw-calls being issued every frame, so you should try to avoid heavy use of LOD trees on platforms that are sensitive to draw-call numbers.

Casting and receiving real-time shadows

To make billboardsA textured 2D object that rotates as it, or the Camera, moves so that it always faces the Camera. See Billboard Renderer
See in Glossary
cast shadows correctly, during the shadow caster pass, billboards are rotated to face the light direction (or light position in the case of point light) instead of facing the cameraA component which creates an image of a particular viewpoint in your scene. The output is either drawn to the screen or captured as a texture. More info
See in Glossary
.

To enable these options, select the Billboard LOD level in the InspectorA Unity window that displays information about the currently selected GameObject, Asset or Project Settings, alowing you to inspect and edit the values. More info
See in Glossary
of an .spm Asset, tick Cast Shadows or Receive Shadows in Billboard Options, and click Apply Prefab.

To change billboard shadow options of instantiated SpeedTree GameObjects, select the billboard GameObject in the Hierarchy window, and tweak these options in the Inspector of the Billboard RendererRenders Billboard Assets, either from a pre-made Asset (exported from SpeedTree) or from a custom-created file that you create using a script at runtime or from a custom editor, for example. More info
See in Glossary
, just as you would with a normal Mesh RendererA mesh component that takes the geometry from the Mesh Filter and renders it at the position defined by the object’s Transform component. More info
See in Glossary
.

Trees painted on the terrain inherit billboard shadow options from the Prefab.

You can use BillboardRenderer.shadowCastingMode and BillboardRenderer.receiveShadows to alter these options at runtime.

Known Issues: As with any other renderer, the Receive Shadows option has no effect while using deferred renderingThe process of drawing graphics to the screen (or to a render texture). By default, the main camera in Unity renders its view to the screen. More info
See in Glossary
. Billboards always receive shadows in deferred path.

对文档有任何疑问,请移步至开发者社区提问,我们将尽快为您解答