A material for CanvasItems.
    public class CanvasItemMaterial : Material

CanvasItemMaterials provide a means of modifying the textures associated with a CanvasItem. They specialize in describing blend and lighting behaviors for textures. Use a ShaderMaterial to more fully customize a material’s interactions with a CanvasItem.

Inheritance Chain

Constructors

    public CanvasItemMaterial()

Properties

    public BlendModeEnum BlendMode { get; set; }

The manner in which a material’s rendering is applied to underlying textures.

    public LightModeEnum LightMode { get; set; }

The manner in which material reacts to lighting.

    public bool ParticlesAnimation { get; set; }

    public int ParticlesAnimHFrames { get; set; }

    public bool ParticlesAnimLoop { get; set; }

    public int ParticlesAnimVFrames { get; set; }

Methods

    [Obsolete("GetBlendMode is deprecated. Use the BlendMode property instead.")]
    public BlendModeEnum GetBlendMode()

Getter for BlendMode

    [Obsolete("GetLightMode is deprecated. Use the LightMode property instead.")]
    public LightModeEnum GetLightMode()

Getter for LightMode

    [Obsolete("GetParticlesAnimation is deprecated. Use the ParticlesAnimation property instead.")]
    public bool GetParticlesAnimation()

Getter for ParticlesAnimation

    [Obsolete("GetParticlesAnimHFrames is deprecated. Use the ParticlesAnimHFrames property instead.")]
    public int GetParticlesAnimHFrames()

Getter for ParticlesAnimHFrames

    [Obsolete("GetParticlesAnimLoop is deprecated. Use the ParticlesAnimLoop property instead.")]
    public bool GetParticlesAnimLoop()

Getter for ParticlesAnimLoop

    [Obsolete("GetParticlesAnimVFrames is deprecated. Use the ParticlesAnimVFrames property instead.")]
    public int GetParticlesAnimVFrames()

Getter for ParticlesAnimVFrames

    [Obsolete("SetBlendMode is deprecated. Use the BlendMode property instead.")]
    public void SetBlendMode(BlendModeEnum blendMode)

Setter for BlendMode

    [Obsolete("SetLightMode is deprecated. Use the LightMode property instead.")]
    public void SetLightMode(LightModeEnum lightMode)

Setter for LightMode

    [Obsolete("SetParticlesAnimation is deprecated. Use the ParticlesAnimation property instead.")]
    public void SetParticlesAnimation(bool particlesAnim)

Setter for ParticlesAnimation

    [Obsolete("SetParticlesAnimHFrames is deprecated. Use the ParticlesAnimHFrames property instead.")]
    public void SetParticlesAnimHFrames(int frames)

Setter for ParticlesAnimHFrames

    [Obsolete("SetParticlesAnimLoop is deprecated. Use the ParticlesAnimLoop property instead.")]
    public void SetParticlesAnimLoop(bool loop)

Setter for ParticlesAnimLoop

    [Obsolete("SetParticlesAnimVFrames is deprecated. Use the ParticlesAnimVFrames property instead.")]
    public void SetParticlesAnimVFrames(int frames)

Setter for ParticlesAnimVFrames

Inner Types

BlendModeEnum

Name Value Description
Mix 0 Mix blending mode. Colors are assumed to be independent of the alpha (opacity) value.
Add 1 Additive blending mode.
Sub 2 Subtractive blending mode.
Mul 3 Multiplicative blending mode.
PremultAlpha 4 Mix blending mode. Colors are assumed to be premultiplied by the alpha (opacity) value.

LightModeEnum

Name Value Description
Normal 0 Render the material using both light and non-light sensitive material properties.
Unshaded 1 Render the material as if there were no light.
LightOnly 2 Render the material as if there were only light.
Tags: