/// <summary>
        /// Register a subsystem implementation.
        /// This should only be used by subsystem implementors.
        /// </summary>
        /// <param name="cinfo">Information used to construct the descriptor.</param>
        public static void RegisterDescriptor(Cinfo cinfo)
        {
#if UNITY_2020_2_OR_NEWER
            SubsystemDescriptorStore.RegisterDescriptor(new XRSessionSubsystemDescriptor(cinfo));
#else
            SubsystemRegistration.CreateDescriptor(new XRSessionSubsystemDescriptor(cinfo));
#endif
        }
        /// <summary>
        /// Creates a new subsystem descriptor and registers it with the <c>SubsystemManager</c>.
        /// </summary>
        /// <param name="cinfo">Constructor info describing the descriptor to create.</param>
        public static void Create(Cinfo cinfo)
        {
#if UNITY_2020_2_OR_NEWER
            SubsystemDescriptorStore.RegisterDescriptor(new XRReferencePointSubsystemDescriptor(cinfo));
#else
            SubsystemRegistration.CreateDescriptor(new XRReferencePointSubsystemDescriptor(cinfo));
#endif
        }
        /// <summary>
        /// Registers a new descriptor with the <c>SubsystemManager</c>.
        /// </summary>
        /// <param name="cinfo">The construction information for the new descriptor.</param>
        public static void Create(Cinfo cinfo)
        {
#if UNITY_2020_2_OR_NEWER
            SubsystemDescriptorStore.RegisterDescriptor(new XRImageTrackingSubsystemDescriptor(cinfo));
#else
            SubsystemRegistration.CreateDescriptor(new XRImageTrackingSubsystemDescriptor(cinfo));
#endif
        }
Exemple #4
0
        /// <summary>
        /// Creates a new subsystem descriptor and registers it with the <c>SubsystemManager</c>.
        /// </summary>
        /// <param name="cinfo">Construction info for the descriptor.</param>
        public static void Create(Cinfo cinfo)
        {
            var descriptor = new XRPlaneSubsystemDescriptor(cinfo);

#if UNITY_2020_2_OR_NEWER
            SubsystemDescriptorStore.RegisterDescriptor(descriptor);
#else
            SubsystemRegistration.CreateDescriptor(descriptor);
#endif
        }
        /// <summary>
        /// Register a provider implementation.
        /// This should only be used by subsystem implementors.
        /// </summary>
        /// <param name="subsystemId">The name of the specific subsystem implementation.</param>
        /// <param name="capabilities">The <see cref="Capabilities"/> of the specific subsystem implementation.</param>
        /// <typeparam name="T">The concrete type derived from <see cref="XRParticipantSubsystem"/> being registered.</typeparam>
        public static void Register <T>(string subsystemId, Capabilities capabilities)
#if UNITY_2020_2_OR_NEWER
            where T : XRParticipantSubsystem.Provider
#else
            where T : XRParticipantSubsystem
#endif
        {
#if UNITY_2020_2_OR_NEWER
            SubsystemDescriptorStore.RegisterDescriptor(new XRParticipantSubsystemDescriptor(subsystemId, typeof(T), null, capabilities));
#else
            SubsystemRegistration.CreateDescriptor(new XRParticipantSubsystemDescriptor(subsystemId, typeof(T), null, capabilities));
#endif
        }
 /// <summary>
 /// Register a provider implementation and subsystem override.
 /// This should only be used by subsystem implementors.
 /// </summary>
 /// <param name="subsystemId">The name of the specific subsystem implementation.</param>
 /// <param name="capabilities">The <see cref="Capabilities"/> of the specific subsystem implementation.</param>
 /// <typeparam name="T">The concrete type derived from <see cref="XRParticipantSubsystem"/> being registered.</typeparam>
 public static void Register <TProvider, TSubsystemOverride>(string subsystemId, Capabilities capabilities)
     where TProvider : XRParticipantSubsystem.Provider
     where TSubsystemOverride : XRParticipantSubsystem
 {
     SubsystemDescriptorStore.RegisterDescriptor(new XRParticipantSubsystemDescriptor(subsystemId, typeof(TProvider), typeof(TSubsystemOverride), capabilities));
 }
Exemple #7
0
 /// <summary>
 /// Register a provider implementation.
 /// This should only be used by subsystem implementors.
 /// </summary>
 /// <param name="subsystemId">The name of the specific subsystem implementation.</param>
 /// <param name="capabilities">The <see cref="Capabilities"/> of the specific subsystem implementation.</param>
 /// <typeparam name="T">The concrete type derived from <see cref="XRParticipantSubsystem"/> being registered.</typeparam>
 public static void Register <T>(string subsystemId, Capabilities capabilities)
     where T : XRParticipantSubsystem.Provider
 {
     SubsystemDescriptorStore.RegisterDescriptor(new XRParticipantSubsystemDescriptor(subsystemId, typeof(T), null, capabilities));
 }
 /// <summary>
 /// Creates a new subsystem descriptor and registers it with the <c>SubsystemManager</c>.
 /// </summary>
 /// <param name="cinfo">Constructor info describing the descriptor to create.</param>
 public static void Create(Cinfo cinfo)
 {
     SubsystemDescriptorStore.RegisterDescriptor(new XRAnchorSubsystemDescriptor(cinfo));
 }
        /// <summary>
        /// Creates a new subsystem descriptor and registers it with the <c>SubsystemManager</c>.
        /// </summary>
        /// <param name="cinfo">Construction info for the descriptor.</param>
        public static void Create(Cinfo cinfo)
        {
            var descriptor = new XRPlaneSubsystemDescriptor(cinfo);

            SubsystemDescriptorStore.RegisterDescriptor(descriptor);
        }
Exemple #10
0
 /// <summary>
 /// Creates a new subsystem descriptor and registers it with the <c>SubsystemManager</c>.
 /// </summary>
 /// <param name="cinfo">Constructor info describing the descriptor to create.</param>
 public static void Create(Cinfo cinfo)
 {
     SubsystemDescriptorStore.RegisterDescriptor(new XRReferencePointSubsystemDescriptor(cinfo));
 }
 /// <summary>
 /// Registers a new descriptor with the <c>SubsystemManager</c>.
 /// </summary>
 /// <param name="cinfo">The construction information for the new descriptor.</param>
 public static void Create(Cinfo cinfo)
 {
     SubsystemDescriptorStore.RegisterDescriptor(new XRImageTrackingSubsystemDescriptor(cinfo));
 }
Exemple #12
0
 /// <summary>
 /// Registers a new descriptor. Should be called by provider implementations.
 /// </summary>
 /// <param name="cinfo"></param>
 public static void RegisterDescriptor(Cinfo cinfo)
 {
     SubsystemDescriptorStore.RegisterDescriptor(new XRRaycastSubsystemDescriptor(cinfo));
 }
Exemple #13
0
 /// <summary>
 /// Register a subsystem implementation.
 /// This should only be used by subsystem implementors.
 /// </summary>
 /// <param name="cinfo">Information used to construct the descriptor.</param>
 public static void RegisterDescriptor(Cinfo cinfo)
 {
     SubsystemDescriptorStore.RegisterDescriptor(new XRSessionSubsystemDescriptor(cinfo));
 }