docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method SetChannelColorMask

    SetChannelColorMask(Channel, bool, float)

    Sets a specific texture channel, for example Channel.R, to a specific color. The channel ignores input tensor values.

    Declaration
    public TextureTransform SetChannelColorMask(Channel c, bool mask, float color)
    Parameters
    Type Name Description
    Channel c

    The color channel to set.

    bool mask

    When the value is false, Sentis ignores color and uses input tensor values.

    float color

    The color value to use.

    Returns
    Type Description
    TextureTransform

    TextureTransform that you can use to chain other methods.

    SetChannelColorMask(bool, bool, bool, bool, Color)

    Sets which channels in the output texture ignore input tensor values and write a specific color instead.

    The method returns a TextureTransform that you can use to chain other methods.

    Declaration
    public TextureTransform SetChannelColorMask(bool maskR, bool maskG, bool maskB, bool maskA, Color color)
    Parameters
    Type Name Description
    bool maskR

    The mask value for the red channel.

    bool maskG

    The mask value for the green channel.

    bool maskB

    The mask value for the blue channel.

    bool maskA

    The mask value for the alpha channel.

    Color color

    The color value to use when masking.

    Returns
    Type Description
    TextureTransform

    TextureTransform that you can use to chain other methods.

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