ModelImporter
- addCollider
- animationCompression
- animationPositionError
- animationRotationError
- animationScaleError
- animationWrapMode
- bakeIK
- clipAnimations
- generateAnimations
- generateMaterials
- generateSecondaryUV
- globalScale
- isBakeIKSupported
- isTangentImportSupported
- isUseFileUnitsSupported
- meshCompression
- normalImportMode
- normalSmoothingAngle
- secondaryUVAngleDistortion
- secondaryUVAreaDistortion
- secondaryUVHardAngle
- secondaryUVPackMargin
- splitAnimations
- splitTangentsAcrossSeams
- swapUVChannels
- tangentImportMode
- useFileUnits
ModelImporter 模型导入器
Inherits from AssetImporter
Model importer lets you modify model import settings from editor scripts.
ModelImporter让你从编辑器脚本修改模型导入设置。
Note: This is an editor class. To use it you have to place your script in Assets/Editor inside your project folder. Editor classes are in the UnityEditor namespace so for C# scripts you need to add "using UnityEditor;" at the beginning of the script.
注意:这是一个编辑器类,如果想使用它你需要把它放到工程目录下的Assets/Editor文件夹下。编辑器类在UnityEditor命名空间下。所以当使用C#脚本时,你需要在脚本前面加上 "using UnityEditor"引用。
Settings of this class match the ones exposed in Mesh Import Settings.
这个类的设置匹配暴露在Mesh Import检视面板中的设置。
Variables变量
-
Material generation options.
材质生成选项。 -
Global scale factor for importing.
用于导入到全局缩放系数。 -
Is useFileUnits supported for this asset.
useFileUnits是否支持这个资源。 -
Detect file units and import as 1FileUnit=1UnityUnit, otherwise it will import as 1cm=1UnityUnit.
检测文件单位并导入,作为1FileUnit = 1UnityUnit,否则将导入作为1cm=1UnityUnit。 -
Add mesh colliders to imported meshes.
添加网格碰撞器给导入的网格。 -
Smoothing angle for calculating normals.
计算法线为平滑角度。 -
Should tangents be split across UV seams.
可以跨越UV接缝分割切线么。 -
Swap primary and secondary UV channels when importing.
当导入时,切换主和次UV通道。 -
Generate secondary UV set for lightmapping.
生成次UV设置为光照图。 -
Threshold for angle distortion when generating secondary UV
当生成次UV,阈值用于角度失真。 -
Threshold for area distortion when generating secondary UV
当生成次UV,阈值用于区域失真。 -
Hard angle for generating secondary UV
对于生成次UV的硬角。 -
Margin to be left between charts when packing secondary UV
在打包次UV时,图之间离开的边距。 -
Animation generation options.
动画生成选项。 -
Normals import mode.
法线导入模式。 -
Tangents import mode.
切线导入模式。 -
Bake Inverse Kinematics (IK) when importing.
当导入时,烘焙反向运动学(IK)。 -
Is Bake Inverse Kinematics (IK) supported by this importer.
是否支持通过导入,烘焙反向运动学(IK)。 -
Is import of tangents supported by this importer.
通过导入器是否支持切线导入。 -
Mesh compression setting.
网格压缩设置。 -
Animation compression setting.
动画压缩设置。 -
Allowed error of animation rotation compression.
允许的动画旋转压缩的误差。 -
Allowed error of animation position compression.
允许的动画位置压缩的误差。 -
Allowed error of animation scale compression.
允许的动画缩放压缩的误差。 -
Should animation be split into multiple clips when importing.
当导入时,动画可以被分为多个剪辑。 -
The default wrap mode for the generated animation clips.
用于生成动画剪辑的默认循环模式。 -
Animation clips to split animation into.
分割动画导入动画剪辑。
Inherited members继承成员
Inherited Variables继承变量
-
The path name of the asset for this importer (Read Only)
用于这个导入器,资源的路径名(只读)。
-
The name of the object. //物体的名字
-
Should the object be hidden, saved with the scene or modifiable by the user?
物体是否被隐藏、保存在场景中或被用户修改?
Inherited Functions继承函数
-
Returns the instance id of the object.
返回物体的实例ID -
Returns the name of the game object.
返回游戏物体的名称。
Inherited Class Functions继承类函数
-
Retrieves the asset importer for the asset at path.
为所在路径的资源,导入器重新获取资源。
-
Does the object exist?
物体是否存在? -
Clones the object original and returns the clone.
克隆原始物体,并返回克隆的物体 -
-
Removes a gameobject, component or asset.
删除一个游戏物体、组件或资源 -
Destroys the object obj immediately. It is strongly recommended to use Destroy instead.
立即销毁物体obj,强烈建议使用Destroy代替。 -
Returns a list of all active loaded objects of Type type.
返回Type类型的所有激活的加载的物体列表 -
Returns the first active loaded object of Type type.
返回Type类型第一个激活的加载的物体。 -
Compares if two objects refer to the same
比较如果两个物体相同 -
Compares if two objects refer to a different object
比较如果两个物体不同 -
Makes the object target not be destroyed automatically when loading a new scene.
加载新场景的时候使目标物体不被自动销毁。
最后修改:2011年6月27日 Monday 16:43