docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Element Opacity node

    Note

    Use this node only in shaders with Material set to UI for UI Toolkit. Using it elsewhere can lead to unexpected behavior or errors. For information on how to create shaders for UI Toolkit, refer to UI Shader Graph.

    Outputs the opacity of a UI element.

    UI Toolkit fades elements with a per-element opacity that isn't part of the raw vertex data. Use this node to read that opacity.

    By default, the shader applies the element's opacity automatically at the end of the fragment stage. If you turn off Automatic Opacity in the Graph Settings, the shader no longer applies it, and you can use this node's output to apply it yourself.

    You can use this node in both the vertex and fragment stages.

    Ports

    Name Direction Type Description
    Opacity Output Vector1 The element's opacity.

    Additional resources

    • Element Tint node
    • Element Texture UV node
    In This Article
    Back to top
    Copyright © 2026 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)