A custom shader program.
    public class Shader : Resource

This class allows you to define a custom shader program that can be used for various materials to render objects.

Inheritance Chain

Derived Classes

Constructors

    public Shader()

Properties

    public string Code { get; set; }

Methods

    [Obsolete("GetCode is deprecated. Use the Code property instead.")]
    public string GetCode()

Getter for Code

    public Texture GetDefaultTextureParam(string param)

    public Mode GetMode()

Returns the shader mode for the shader, either [constant MODE_CANVAS_ITEM], [constant MODE_SPATIAL] or [constant MODE_PARTICLES]

    public bool HasParam(string name)

    [Obsolete("SetCode is deprecated. Use the Code property instead.")]
    public void SetCode(string code)

Setter for Code

    public void SetDefaultTextureParam(string param, Texture texture)

Inner Types

Mode

Name Value Description
Spatial 0  
CanvasItem 1  
Particles 2  
Tags: