docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method SetKeyword

    SetKeyword(CommandBuffer, string, bool)

    Set a global keyword using a CommandBuffer

    Declaration
    public static void SetKeyword(CommandBuffer cmd, string keyword, bool state)
    Parameters
    Type Name Description
    CommandBuffer cmd

    CommandBuffer on which to set the global keyword.

    string keyword

    Keyword to be set.

    bool state

    Value of the keyword to be set.

    SetKeyword(BaseCommandBuffer, string, bool)

    Set a global keyword using a RasterCommandBuffer

    Declaration
    public static void SetKeyword(BaseCommandBuffer cmd, string keyword, bool state)
    Parameters
    Type Name Description
    BaseCommandBuffer cmd

    CommandBuffer on which to set the global keyword.

    string keyword

    Keyword to be set.

    bool state

    Value of the keyword to be set.

    SetKeyword(Material, string, bool)

    Set a keyword immediatly on a Material.

    Declaration
    public static void SetKeyword(Material material, string keyword, bool state)
    Parameters
    Type Name Description
    Material material

    Material on which to set the keyword.

    string keyword

    Keyword to set on the material.

    bool state

    Value of the keyword to set on the material.

    SetKeyword(ComputeShader, string, bool)

    Set a keyword to a compute shader

    Declaration
    public static void SetKeyword(ComputeShader cs, string keyword, bool state)
    Parameters
    Type Name Description
    ComputeShader cs

    Compute Shader on which to set the keyword.

    string keyword

    Keyword to be set.

    bool state

    Value of the keyword to be set.

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)