UnigineScript
The Language
Core Library
Engine Library
Node-Related Classes
GUI-Related Classes
Plugins Library
High-Level Systems
Samples
C++ API
API Reference
Integration Samples
Usage Examples
C++ Plugins
Content Creation
Materials
Unigine Material Library
Tutorials

DecalDeferredMesh Class

This class describes how to create and modify mesh deferred decals.

DecalDeferredMesh Class

This class inherits from DecalDeferred

Members


DecalDeferredMesh (string name, float radius, string material)

Constructor. Creates a new DecalDeferredMesh object with the given properties.

Arguments

  • string name - Name of the mesh to be used as a base for a decal.
  • float radius - The height of the decal projection box along the Z axis, in units.
  • string material - Material of the decal.

int getMesh (ObjectMesh mesh)

Returns a mesh used as a base for the decal.

Arguments

  • ObjectMesh mesh - Name of the mesh node.

Return value

Mesh node.

float getRadius ()

Returns the current height of the decal projection box along the Z axis.

Return value

The height of the decal projection box along the Z axis, in units.

int load (string name)

Loads a mesh file and re-generates the DecalDeferredMesh object.

Arguments

  • string name - Name of the mesh file.

Return value

1 if the mesh is successfully loaded, otherwise - 0.

int save (string name)

Saves the DecalDeferredMesh object into a mesh file with given name.

Arguments

  • string name - Name of the mesh file.

Return value

1 if the DecalDeferredMesh object is successfully saved, otherwise - 0.

int setMesh (ObjectMesh mesh)

Sets a new mesh node for the DecalDeferredMesh object.

Arguments

  • ObjectMesh mesh - Name of the mesh node.

Return value

1 if the mesh node is successfully set, otherwise - 0.

void setRadius (float radius)

Sets the new height of the decal projection box along the Z axis.

Arguments

  • float radius - The height of the decal projection box along the Z axis, in units.
Last update: 2017-07-03