Node used for displaying a Mesh in 2D.
    public class MeshInstance2D : Node2D

Node used for displaying a Mesh in 2D. Can be constructed from an existing Sprite use tool in Toolbar. Select “Sprite” then “Convert to Mesh2D”, select settings in popup and press “Create Mesh2D”.

Inheritance Chain

Constructors

    public MeshInstance2D()

Signals

    "texture_changed" ()

Properties

    public Mesh Mesh { get; set; }

The Mesh that will be drawn by the MeshInstance2D.

    public Texture NormalMap { get; set; }

The normal map that will be used if using the default CanvasItemMaterial.

    public Texture Texture { get; set; }

The Texture that will be used if using the default CanvasItemMaterial. Can be accessed as TEXTURE in CanvasItem shader.

Methods

    [Obsolete("GetMesh is deprecated. Use the Mesh property instead.")]
    public Mesh GetMesh()

Getter for Mesh

    [Obsolete("GetNormalMap is deprecated. Use the NormalMap property instead.")]
    public Texture GetNormalMap()

Getter for NormalMap

    [Obsolete("GetTexture is deprecated. Use the Texture property instead.")]
    public Texture GetTexture()

Getter for Texture

    [Obsolete("SetMesh is deprecated. Use the Mesh property instead.")]
    public void SetMesh(Mesh mesh)

Setter for Mesh

    [Obsolete("SetNormalMap is deprecated. Use the NormalMap property instead.")]
    public void SetNormalMap(Texture normalMap)

Setter for NormalMap

    [Obsolete("SetTexture is deprecated. Use the Texture property instead.")]
    public void SetTexture(Texture texture)

Setter for Texture

Tags: