docs.unity3d.com
    Show / Hide Table of Contents

    Struct RenderFilterSettings

    Represents settings that control when to render a given entity.

    Namespace: Unity.Entities.Graphics
    Syntax
    public struct RenderFilterSettings : ISharedComponentData, IQueryTypeParameter, IEquatable<RenderFilterSettings>
    Remarks

    For example, you can set the layermask of the entity and also set whether to render an entity in shadow maps or motion passes.

    Fields

    Layer

    The LayerMask index.

    Declaration
    public int Layer
    Field Value
    Type Description
    Int32
    Remarks

    For entities that Unity converts from GameObjects, this value is the same as the Layer setting of the source GameObject.

    MotionMode

    Specifies what kinds of motion vectors to generate for the entity, if any.

    Declaration
    public MotionVectorGenerationMode MotionMode
    Field Value
    Type Description
    MotionVectorGenerationMode
    Remarks

    This value corresponds to motionVectorGenerationMode.

    This value only affects render pipelines that use motion vectors.

    ReceiveShadows

    Indicates whether to cast shadows onto the entity.

    Declaration
    public bool ReceiveShadows
    Field Value
    Type Description
    Boolean
    Remarks

    For entities that Unity converts from GameObjects, this value is the same as the Receive Shadows property of the source Mesh Renderer component. This value only affects Progressive Lightmappers.

    RenderingLayerMask

    The rendering layer the entity is part of.

    Declaration
    public uint RenderingLayerMask
    Field Value
    Type Description
    UInt32
    Remarks

    This value corresponds to renderingLayerMask.

    ShadowCastingMode

    Specifies how the entity should cast shadows.

    Declaration
    public ShadowCastingMode ShadowCastingMode
    Field Value
    Type Description
    ShadowCastingMode
    Remarks

    For entities that Unity converts from GameObjects, this value is the same as the Cast Shadows property of the source Mesh Renderer component. For more information, refer to ShadowCastingMode.

    StaticShadowCaster

    Indicates whether the entity is a static shadow caster.

    Declaration
    public bool StaticShadowCaster
    Field Value
    Type Description
    Boolean
    Remarks

    This value is important to the BatchRenderGroup.

    Properties

    Default

    Returns a new default instance of RenderFilterSettings.

    Declaration
    public static readonly RenderFilterSettings Default { get; }
    Property Value
    Type Description
    RenderFilterSettings

    IsInMotionPass

    Indicates whether the motion mode for the current pass is not camera.

    Declaration
    public readonly bool IsInMotionPass { get; }
    Property Value
    Type Description
    Boolean

    Methods

    Equals(Object)

    Indicates whether the current instance is equal to the specified object.

    Declaration
    public override bool Equals(object obj)
    Parameters
    Type Name Description
    Object obj

    The object to compare with the current instance.

    Returns
    Type Description
    Boolean

    Returns true if the current instance is equal to the specified object. Otherwise, returns false.

    Overrides
    ValueType.Equals(Object)

    Equals(RenderFilterSettings)

    Indicates whether the current instance is equal to the specified RenderFilterSettings.

    Declaration
    public bool Equals(RenderFilterSettings other)
    Parameters
    Type Name Description
    RenderFilterSettings other

    The RenderFilterSettings to compare with the current instance.

    Returns
    Type Description
    Boolean

    Returns true if the current instance is equal to the specified RenderFilterSettings. Otherwise, returns false.

    GetHashCode()

    Calculates the hash code for this object.

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    Int32

    The hash code.

    Overrides
    ValueType.GetHashCode()

    Operators

    Equality(RenderFilterSettings, RenderFilterSettings)

    Declaration
    public static bool operator ==(RenderFilterSettings left, RenderFilterSettings right)
    Parameters
    Type Name Description
    RenderFilterSettings left
    RenderFilterSettings right
    Returns
    Type Description
    Boolean

    Inequality(RenderFilterSettings, RenderFilterSettings)

    Declaration
    public static bool operator !=(RenderFilterSettings left, RenderFilterSettings right)
    Parameters
    Type Name Description
    RenderFilterSettings left
    RenderFilterSettings right
    Returns
    Type Description
    Boolean
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023