Struct Renderer2D | Project Tiny | 0.31.0-preview.24
docs.unity.cn
    Show / Hide Table of Contents

    Struct Renderer2D

    Component that holds general 2D rendering data.

    Namespace: Unity.Tiny
    Syntax
    public struct Renderer2D : IComponentData

    Fields

    Bounds

    Local bounds of the Renderer.

    Declaration
    public AABB Bounds
    Field Value
    Type Description
    AABB

    -

    OrderInLayer

    The Order in Layer value of the Renderer, which determines its render priority within its Sorting Layer.

    Declaration
    public short OrderInLayer
    Field Value
    Type Description
    Int16

    Lower valued Renderers are rendered first, with higher valued Renderers overlapping them and appearing closer to the camera.

    RenderingLayer

    The Layer the Renderer is in. Layers can be used for selective rendering from the camera.

    Declaration
    public int RenderingLayer
    Field Value
    Type Description
    Int32

    The Layer needs to be within the range of [0...31].

    SortingLayer

    The Sorting Layer that the Renderer is set to, which determines its priority in the render queue.

    Declaration
    public short SortingLayer
    Field Value
    Type Description
    Int16

    Lower valued Renderers are rendered first, with higher valued Renderers overlapping them and appearing closer to the camera.

    Back to top Copyright © 2020 Unity Technologies
    Generated by DocFX
    on 06 November 2020