docs.unity3d.com
    目次を表示する/隠す

    Class LoaderUtility

    A utility for interacting with an XRLoader from XR Management.

    Inheritance
    Object
    LoaderUtility
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: UnityEngine.XR.ARFoundation
    Syntax
    public static class LoaderUtility
    Remarks

    XR Management controls the lifecycle of subsystems. Components in AR Foundation, such as ARSession or ARPlaneManager, turn subsystems on and off, but do not create or destroy them. Therefore, subsystems can persist across many scenes. They are automatically created on app startup, but are not destroyed during a scene switch. This allows you to keep the same session alive between scenes, for example.

    Methods

    Deinitialize()

    Deinitializes the currently active XR Loader, if one exists. This destroys all subsystems.

    Declaration
    public static bool Deinitialize()
    Returns
    Type Description
    Boolean

    Returns true if there is an active loader and its Deinitialize method returns true. Returns false otherwise.

    GetActiveLoader()

    Get the 'active' loader from XR Management.

    Declaration
    public static XRLoader GetActiveLoader()
    Returns
    Type Description
    XRLoader

    Returns the currently active XRLoader.

    Initialize()

    Initializes the currently active XR Loader, if one exists. This creates all subsystems.

    Declaration
    public static bool Initialize()
    Returns
    Type Description
    Boolean

    Returns true if there is an active loader and its Initialize method returns true. Returns false otherwise.

    トップに戻る
    Copyright © 2023 Unity Technologies — 商標と利用規約
    • 法律関連
    • プライバシーポリシー
    • クッキー
    • 私の個人情報を販売または共有しない
    • Your Privacy Choices (Cookie Settings)