Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


SpeedTreeImporter

AssetImporter for importing SpeedTree model assets.
Read time 7 minutesLast updated 2 days ago

Definition

public class SpeedTreeImporter : AssetImporter

Static Fields

Value

Description

windQualityNamesGets an array of name strings for wind quality value.

Constructors

Constructor

Description

SpeedTreeImporter()Construct a new SpeedTreeImporter object.

Properties

Property

Description

alphaTestRefGets and sets a default alpha test reference values.
animateCrossFadingIndicates if the cross-fade LOD transition, applied to the last mesh LOD and the billboard, should be animated.
bestWindQualityReturns the best-possible wind quality on this asset (configured in SpeedTree modeler).
billboardTransitionCrossFadeWidthProportion of the last 3D mesh LOD region width which is used for cross-fading to billboard tree.
castShadowsGets and sets an array of booleans to enable shadow casting for each LOD.
castShadowsByDefaultGets and sets a boolean to toggle whether the imported SpeedTree casts shadows.
defaultBillboardShaderReturns the default SpeedTree billboard shader for the active render pipeline, or
null
if the asset is a SpeedTree v8 asset.
defaultShaderReturns the default SpeedTree shader for the active render pipeline (either v7 or v8 according to the asset version).
enableBumpGets and sets an array of booleans to enable normal mapping for each LOD.
enableBumpByDefaultGets and sets a boolean to enable normal mapping on the imported SpeedTree model.
enableHueGets and sets an array of booleans to enable hue variation effect for each LOD.
enableHueByDefaultGets and sets a boolean to enable hue variation effect on the imported SpeedTree model.
enableSettingOverrideGets and sets an array of booleans to customize importer settings for a specific LOD.
enableSmoothLODTransitionEnables smooth LOD transitions.
enableSubsurfaceGets and sets an array of booleans to enable the subsurface scattering effect for each LOD (affects only SpeedTree v8 assets).
enableSubsurfaceByDefaultGets and sets a boolean to enable the subsurface scattering effect for the SpeedTree asset (affects only SpeedTree v8 assets).
fadeOutWidthProportion of the billboard LOD region width which is used for fading out the billboard.
generateCollidersGets and sets the boolean to toggle collider object generation during import.
generateRigidbodyGets and sets the boolean to toggle Rigidbody generation during import.
hasBillboardTells if there is a billboard LOD.
hasImportedTells if the SPM file has been previously imported.
hueVariationGets and sets a default hue variation color and amount (in alpha).
isV8Returns true if the asset is a SpeedTree v8 asset.
LODHeightsGets and sets an array of floats of each LOD's screen height value.
mainColorGets and sets a default main color.
materialFolderPathReturns the folder path where generated materials will be placed in.
materialLocationMaterial import location options.
receiveShadowsGets and sets an array of booleans to enable shadow receiving for each LOD.
receiveShadowsByDefaultGets and sets a boolean to enable whether the SpeedTree asset receives shadows from other objects in your scene.
scaleFactorHow much to scale the tree model compared to what is in the imported SpeedTree model file.
selectedWindQualityGets and sets an integer corresponding to the SpeedTreeWind enum values. The value is clamped by SpeedTreeImporter.bestWindQuality internally.
useLightProbesGets and sets an array of booleans to enable Light Probe lighting for each LOD.
useLightProbesByDefaultGets and sets a boolean to enable light probe lighting for the imported SpeedTree model.
windQualitiesGets and sets an array of integers of the wind qualities on each LOD. Values will be clamped by SpeedTreeImporter.bestWindQuality internally.

Methods

Method

Description

GenerateMaterialsGenerates all necessary materials under materialFolderPath. If Version Control is enabled please first check out the folder.
SearchAndRemapMaterialsSearch the project for matching materials and use them instead of the internal materials.

Enums

Enum

Description

SpeedTreeImporter.MaterialLocationMaterial import location options.

Inheritance

Inherited Members

Operators

Operator

Description

operator ==Compares two object references to see if they refer to the same object.
boolDetermines whether the object exists.
operator !=Compares if two objects refer to a different object.