docs.unity.cn
    Show / Hide Table of Contents

    Class TrackingModeExtensions

    Extensions for the TrackingMode and Feature enums, allowing conversion between the two.

    Inheritance
    Object
    TrackingModeExtensions
    Namespace: UnityEngine.XR.ARFoundation
    Syntax
    public static class TrackingModeExtensions

    Methods

    ToFeature(TrackingMode)

    Converts a TrackingMode to a UnityEngine.XR.ARSubsystems.Feature.

    Declaration
    public static Feature ToFeature(this TrackingMode self)
    Parameters
    Type Name Description
    TrackingMode self

    The TrackingMode being extended.

    Returns
    Type Description
    Feature

    A Feature with the appropriate tracking mode bits set.

    ToTrackingMode(Feature)

    Converts a UnityEngine.XR.ARSubsystems.Feature to a TrackingMode.

    Declaration
    public static TrackingMode ToTrackingMode(this Feature self)
    Parameters
    Type Name Description
    Feature self

    The Feature being extended.

    Returns
    Type Description
    TrackingMode

    The TrackingMode representation of self.

    Back to top Copyright © 2022 Unity Technologies
    Generated by DocFX
    on Monday, November 7, 2022
    Terms of use