This page has been translated automatically.
UnigineEditor
Interface Overview
Assets Workflow
Settings and Preferences
Adjusting Node Parameters
Setting Up Properties
Landscape Tool
Using Editor Tools for Specific Tasks
FAQ
Programming
Fundamentals
Setting Up Development Environment
Usage Examples
UnigineScript
C++
C#
UUSL (Unified UNIGINE Shader Language)
File Formats
Rebuilding the Engine and Tools
GUI
Double Precision Coordinates
API
Containers
Common Functionality
Controls-Related Classes
Engine-Related Classes
Filesystem Functionality
GUI-Related Classes
Math Functionality
Node-Related Classes
Networking Functionality
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
CIGI Client Plugin
Rendering-Related Classes
Warning! This version of documentation is OUTDATED, as it describes an older SDK version! Please switch to the documentation for the latest SDK version.
Warning! This version of documentation describes an old SDK version which is no longer supported! Please upgrade to the latest SDK version.

Organizing Materials

UNIGINE materials are organized in a hierarchy and managed via the Materials Hierarchy window.

Materials Hierarchy Window

The Materials Hierarchy window provides access to all materials of the project and allows filtering them by names, collapsing materials hierarchy (i.e., showing only the base materials and hiding the user ones), inheriting, cloning, renaming, and deleting materials.

All materials in the hierarchy are linked to the .basemat and .mat material files stored in the assets folder of the project and available via the Asset Browser. So, any operation on a material via the UnigineEditor interface updates the corresponding asset.

To open the Materials Hierarchy window, choose Windows -> Toggle Materials Hierarchy in the Menu Bar or press M.

See Also

Creating a Material

A material can be created via UnigineEditor in one of the following ways:

The new material is automatically added to the materials hierarchy and displayed in the Materials Hierarchy window. The asset, to which the new material links, is also created and becomes available via the Asset Browser.

Notice
Materials in the hierarchy are sorted alphabetically by names, so you cannot rearrange them.

Basic Operations on a Material

The Materials Hierarchy window allows the following basic operations on a material.

Renaming a Material

To rename a material, right-click it and choose Rename in the drop-down list.

Renaming a Material

You can also rename a material via the Parameters window by editing the Name field.

Notice
Only the user materials can be renamed. Renaming a material leads renaming the asset file it is linked.

If you rename a material asset via the Asset Browser, the material that links to it will be renamed as well.

Cloning a Material

To clone a material, right-click it and choose Clone in the drop-down list.

Cloning a Material

Another way to clone a material is to select it and click to the left of the material name filter.

Notice
Only the user materials can be cloned. Cloning a material leads creating an asset file, to which the new material links.
The new material will be created at the same hierarchy level as the original one. Note that the child materials won't be cloned.

If you copy a material file via the Asset Browser, the material that links to it will be cloned.

Deleting a Material

To delete a material, right-click it, choose Delete in the drop-down list and confirm deletion in the dialog window that opens:

Deleting a Material

Another way to delete a material is to select it and click to the left of the material name filter. If you delete a parent material, all its child materials will be deleted as well.

Notice
Deleting a material leads deleting the asset file it is linked. You cannot undo material's deletion.

If you delete a material file via the Asset Browser, the material that links to it will be deleted as well.

Setting Up Materials Inheritance

In UNIGINE, materials are organized in a hierarchy, like nodes, but are completely independent of the nodes hierarchy. Each material (parent material) can have multiple children (child materials). The parent material can be both the base or user material; the child material is always a user material.

To collapse or expand the list of child materials, click the arrow to the left of the parent material. You can also collapse all child materials in the Materials Hierarchy window by clicking .

Inheriting a Material

Inheriting one material from another allows forming the materials hierarchy. To inherit a new material from the existing one, right-click the desired parent material and choose Inherit in the drop-down list.

Inheriting a Material

Another way to inherit a material is to select it and click to the left of the material name filter.

Notice
Inheriting a material leads creating a new asset file.

You can also inherit a new material via the Parameters window: select a surface, go to the Material section and click right to the field with the material name. The inherited material will be assigned to the currently selected surface automatically.

Notice
The child material asset is created in the same folder as the parent material asset. If the material is inherited from the base material, the asset will be created in the root of the asset folder.

Inheriting via Asset Browser

To inherit a material via the Asset Browser, select the material asset, right-click it and choose Inherit in the drop-down list. The new material will be added to the Materials Hierarchy window and linked to the created asset.

Inheriting a Material via Asset Browser

Reparenting a Material

To change the parent material (reparent), select the target material in the hierarchy and drag it with the left mouse button pressed to the desired parent.

Reparenting a Material

The parent material, to which the child material will be added, is highlighted with the white frame:

Highlighted Parent Material

You can also move the material to a position alongside the child materials of the desired parent: the material will be added as a child to this parent material in alphabetical order. The position in the hierarchy is highlighted with the white line during moving.

Reparenting a Material

Assigning a Material

A material can be assigned to the entire node (i.e., to all its surfaces), several surfaces or a single surface of the node.

To assign a material to a surface (or surfaces) of a node, select the node, select the target surface (surfaces) and perform one of the following:

Notice
To assign a material to the entire node, selecting the node will be enough: the material will be assigned to all its surfaces.
  • Drag the material from the Materials Hierarchy window or the icon of the material asset from the Asset Browser to the field with the material asset name in the Parameters window.

  • Drag the material from the Materials Hierarchy window or the icon of the material asset from the Asset Browser to the target surface in the Scene Viewport.

  • Use the button next to the field with the material asset name in the Parameters window (the Node tab) to choose the desired material asset.

  • Type the name of the material asset to the field with the material asset name in the Parameters window (the Node tab) manually. If an asset with the specified name exists in the project, it will be shown in the drop-down list while typing.

Last update: 2018-04-26
Build: ()