This page has been translated automatically.
视频教程
界面
要领
高级
实用建议
UnigineEditor
界面概述
资产工作流程
设置和首选项
项目开发
调整节点参数
Setting Up Materials
Setting Up Properties
照明
Landscape Tool
Sandworm
使用编辑器工具执行特定任务
Extending Editor Functionality
嵌入式节点类型
Nodes
Objects
Effects
Decals
光源
Geodetics
World Nodes
Sound Objects
Pathfinding Objects
Players
编程
基本原理
搭建开发环境
Usage Examples
UnigineScript
C++
C#
UUSL (Unified UNIGINE Shader Language)
File Formats
Rebuilding the Engine Tools
GUI
双精度坐标
应用程序接口
Containers
Common Functionality
Controls-Related Classes
Engine-Related Classes
Filesystem Functionality
GUI-Related Classes
Math Functionality
Node-Related Classes
Objects-Related Classes
Networking Functionality
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
IG Plugin
CIGIConnector Plugin
Rendering-Related Classes
创建内容
Materials
Art Samples
Tutorials

使用冒名顶替者

When the scene contains a lot of objects that should be visible at large distances, the application performance suffers. To reduce the number of such objects, impostors are used. They allow speeding up geometry rendering while saving visual fidelity: each impostor repeats transformation and appearance of the original object.当场景包含许多应在远距离可见的对象时,应用程序性能会受到影响。为了减少此类对象的数量,使用了冒号。它们可以在节省视觉保真度的同时加快几何渲染速度:每个冒名顶替者都重复原始对象的变换和外观。

UNIGINE provides the Impostors Creator tool that allows generating impostors for a single object or for objects baked into a Mesh Clutter:UNIGINE 提供了Impostors Creator工具,该工具可为单个对象或烘焙到Mesh Clutter中的对象生成冒名顶替者:

  • In the first case, the billboards-based impostor will be rendered instead of the real object.在第一种情况下,将呈现基于基于广告牌的冒名顶替者,而不是真实对象。
  • In the second case, the Grass object will be rendered instead of the Mesh Clutter.在第二种情况下,将呈现Grass对象而不是Mesh Clutter

For example, you can replace the distant trees with impostors to optimize forest rendering:例如,您可以使用冒名顶替者替换远处的树木,以优化森林渲染:

Forest Optimized by Using Impostor Trees使用发布者树优化的森林
注意
Generating impostors is shown in the Content Optimization video tutorial, it is available both for a single object and for objects baked into a Mesh Cluster.内容优化视频教程中显示了生成冒名顶替者,它既可用于单一物件,也可用于烘焙到Mesh Cluster中的对象。

1. Grabbing Impostors1.抢夺冒名顶替者#

注意
Grabbing of impostors is not supported for objects with transparent materials. E.g. if you have an object using a material with Alpha Blend preset enabled, the impostor generated for it will not be displayed.带有透明材料的物体不支持抓取冒名顶替者。例如。如果您的对象使用启用了Alpha Blend预设的材质,则不会显示为其生成的冒名顶替者。

To grab impostor with the Impostors Creator tool, perform the following:要使用Impostors Creator工具抓住冒名顶替者,请执行以下操作:

  1. In the Menu Bar, choose Tools -> Impostors Creator. The Impostors Creator tool will open.

    在菜单栏中,选择Tools -> Impostors Creator。的Impostors Creator工具将打开。

  2. In the World Hierarchy window, choose a single mesh or a clutter, for which an impostor should be created.
    注意
    Impostors can be generated only for Mesh Clutter objects, World Clutter isn't supported.Impostors can be generated only for Mesh Clutter objects, World Clutter isn't supported.
    • If you choose a mesh, a single impostor represented by the Billboards object will be generated.If you choose a mesh, a single impostor represented by the Billboards object will be generated.
    • If you choose a clutter, impostors for all clutter objects represented by the Grass object will be generated.If you choose a clutter, impostors for all clutter objects represented by the Grass object will be generated.
    Impostors can be generated only for Mesh Clutter objects, World Clutter isn't supported.If you choose a mesh, a single impostor represented by the Billboards object will be generated.If you choose a clutter, impostors for all clutter objects represented by the Grass object will be generated.
    在里面World Hierarchy窗口中,选择要为其创建冒名顶替者的单个网格杂波
    注意
    Impostors can be generated only for Mesh Clutter objects, World Clutter isn't supported.伪造者只能为Mesh Clutter个对象生成,不支持World Clutter
    • If you choose a mesh, a single impostor represented by the Billboards object will be generated.如果选择网格,则会生成由 将生成由Billboards对象表示的单个冒名顶替者
    • If you choose a clutter, impostors for all clutter objects represented by the Grass object will be generated.如果选择杂波,则将生成由Grass对象代表的所有杂波对象都将生成。
  3. In the Impostors Creator window, specify the required textures and settings.
    注意
    If you are going to generate the impostors for vegetation, you should specify For Vegetation option for textures (where available).If you are going to generate the impostors for vegetation, you should specify For Vegetation option for textures (where available).
    If you are going to generate the impostors for vegetation, you should specify For Vegetation option for textures (where available).
    在里面Impostors Creator窗口中,指定所需的纹理设置
    注意
    If you are going to generate the impostors for vegetation, you should specify For Vegetation option for textures (where available).如果要生成植被的冒名顶替者,则应为纹理指定For Vegetation选项(如果可用)。
  4. Click Create and specify a name for textures in the file dialog window that opens.单击Create,然后在打开的文件对话框窗口中为纹理指定名称。

The generated impostor(s) will be added as a child node to the original mesh/clutter:生成的冒名顶替者将作为子节点添加到原始网格/杂波中:

  • For objects baked into the clutter, the Grass object with the material inherited from grass_impostor_base will be added. All required settings will be copied from the original Mesh Clutter to the Grass object automatically.

    Real Clutter Objects and Its Impostors in SceneReal Clutter Objects and Its Impostors in Scene
    Objects and Impostors WireframesObjects and Impostors Wireframes
    Real Clutter Objects and Its Impostors in SceneObjects and Impostors Wireframes
    对于杂乱无章的对象, Grass 对象具有从中继承的材质grass_impostor_base将被添加。所有必需的设置都会从原始文件中复制Mesh ClutterGrass自动对象。

    Real Clutter Objects and Its Impostors in Scene场景中的真实杂物及其伪装者
    Objects and Impostors Wireframes对象和假名线框
  • For a single object, the Billboards object with the material inherited from billboards_impostor_base will be added.

    Real Object (left) and Its Impostor (right) in SceneReal Object (left) and Its Impostor (right) in Scene
    Object and Impostor WireframesObject and Impostor Wireframes
    Real Object (left) and Its Impostor (right) in SceneObject and Impostor Wireframes
    对于单个对象,Billboards具有从中继承的材料的对象billboards_impostor_base将被添加。

    Real Object (left) and Its Impostor (right) in Scene场景中的真实对象(左)及其伪装者(右)
    Object and Impostor Wireframes对象和假名线框

2. Setting Up Impostor Material2.设置冒名顶替者材料#

All textures specified in the Impostors Creator are generated in the data folder and applied in the material automatically. The impostor material may require additional set up: Impostors Creator中指定的所有纹理均在data文件夹中生成,并自动应用于材质中。冒充者的材料可能需要其他设置:

  • If you grab only the Albedo and Normal textures, you will have to manually set up the other shading parameters of the impostor material (Specular, Translucence, etc.), so that the impostor visually match the original object. However, if the original object has several surfaces with different shading, the impostors may significantly differ (so it is better to grab all textures in this case).如果仅获取AlbedoNormal纹理,则必须手动设置冒名顶替者材料的其他着色参数(Specular, Translucence等),以便冒名顶替者在视觉上与原始对象匹配。但是,如果原始对象的多个表面具有不同的阴影,则冒名顶替者可能会显着不同(因此,在这种情况下最好抓取所有纹理)。
  • For vegetation impostors, the Specular parameter should be set to 0 to avoid unnecessary specks on trees.对于植被冒名顶替者,应将Specular参数设置为 0 ,以避免在树上产生不必要的斑点。
  • If you simply want to improve visual representation of impostors, you can adjust shading parameters (for example, increase Translucence for trees impostors and so on).如果您只是想改善冒名顶替者的外观,则可以调整阴影参数(例如,为树木冒名顶替者增加Translucence等)。
最新更新: 2020-10-02
Build: ()