Model files can contain a variety of data, such as character and terrain Meshes, Animation Rigs and Clips, as well as Materials and Textures. Most likely, your file does not contain all of these elements at once, but you can follow any portion of the workflow that you need to:
Note: This workflow assumes you already have a Model file to import. If you don’t have a file already, you can read the guidelines on how to export an FBX file before exporting it from your 3D modeling software. For guidelines on how to export Humanoid animation from your 3D modeling software, see Humanoid Asset preparation.
无论要从模型文件中提取哪种数据,始终以相同的方式开始:
1.打开 Project 窗口和 __Inspector__,确保能同时看到这两个界面。
Select the Model file you want to import from the Asset folder in the Project window.
The Import Settings window opens in the Inspector showing the Model tab by default.
The options that are available for SpeedTree Models vs. other Models are very different. For example, the SpeedTree Model tab provides options mostly for setting up transitions between LOD levels.
Character and animated Models provide more diverse options on their Model tab, which allow you to:
如果文件包含动画数据,可遵循使用 Rig 选项卡设置骨架并使用 Animation 选项卡提取或定义动画剪辑的准则。人形和通用(非人形)动画类型的工作流程不同,因为 Unity 要求人形类型有非常具体的骨骼结构,但对于通用类型只需了解哪个骨骼是根节点:
Note: SpeedTree Models have neither a Rig nor an Animation tab.
如果文件包含__材质__或__纹理__,可定义它们的处理方式:
1.单击 Import Settings 窗口中的 Materials 选项卡。 2.启用 Import Materials 选项。Materials 选项卡中显示多个选项,包括 Location 选项,该选项的值决定了应显示的其他选项。 3.选择 Use Embedded Materials 选项将导入的材质保持在导入的资源中。 4. When you have finished setting the options, click the Apply button at the bottom of the Import Settings window to save them or click the Revert button to cancel.
最后,可将文件导入场景中: