コード例 #1
0
 internal static void Register()
 {
     XRPlaneSubsystemDescriptor.Create(new XRPlaneSubsystemDescriptor.Cinfo
     {
         id = ID,
         subsystemImplementationType      = typeof(UnityXRMockPlaneSubsystem),
         supportsHorizontalPlaneDetection = true,
         supportsVerticalPlaneDetection   = true,
         supportsArbitraryPlaneDetection  = true,
         supportsBoundaryVertices         = true
     });
 }
コード例 #2
0
 internal static void Register()
 {
     XRPlaneSubsystemDescriptor.Create(new XRPlaneSubsystemDescriptor.Cinfo
     {
         id                               = typeof(UnityXRMockPlaneSubsystem).FullName,
         providerType                     = typeof(MockProvider),
         subsystemTypeOverride            = typeof(UnityXRMockPlaneSubsystem),
         supportsHorizontalPlaneDetection = true,
         supportsVerticalPlaneDetection   = true,
         supportsArbitraryPlaneDetection  = true,
         supportsBoundaryVertices         = true,
         supportsClassification           = true
     });
 }
コード例 #3
0
        static void RegisterDescriptor()
        {
            var cinfo = new XRPlaneSubsystemDescriptor.Cinfo
            {
                id = "ARCore-Plane",
                subsystemImplementationType      = typeof(ARCorePlaneProvider),
                supportsHorizontalPlaneDetection = true,
                supportsVerticalPlaneDetection   = true,
                supportsArbitraryPlaneDetection  = false,
                supportsBoundaryVertices         = true
            };

            XRPlaneSubsystemDescriptor.Create(cinfo);
        }
コード例 #4
0
        static void RegisterDescriptor()
        {
#if UNITY_IOS && !UNITY_EDITOR
            var cinfo = new XRPlaneSubsystemDescriptor.Cinfo
            {
                id = "ARKit-Plane",
                subsystemImplementationType      = typeof(ARKitXRPlaneSubsystem),
                supportsHorizontalPlaneDetection = true,
                supportsVerticalPlaneDetection   = true,
                supportsArbitraryPlaneDetection  = false,
                supportsBoundaryVertices         = true
            };

            XRPlaneSubsystemDescriptor.Create(cinfo);
#endif
        }
コード例 #5
0
 internal static void RegisterDescriptor(XRPlaneSubsystemDescriptor descriptor, Func <XRPlaneSubsystem, TrackableId, TrackingState> getTrackingState)
 {
     if (descriptor != null)
     {
         descriptor.subsystemImplementationType = typeof(UnityXRMockPlaneProvider);
     }
     else
     {
         XRPlaneSubsystemDescriptor.Create(new XRPlaneSubsystemDescriptor.Cinfo
         {
             id = "UnityXRMock-Plane",
             subsystemImplementationType      = typeof(UnityXRMockPlaneProvider),
             supportsHorizontalPlaneDetection = true,
             supportsVerticalPlaneDetection   = true,
             supportsArbitraryPlaneDetection  = true,
             supportsBoundaryVertices         = true
         });
     }
 }
コード例 #6
0
        static void RegisterDescriptor()
        {
#if UNITY_EDITOR
            const string id    = "ARKit-Remote-Plane";
            var          cinfo = new XRPlaneSubsystemDescriptor.Cinfo
            {
                id = id,
                subsystemImplementationType      = typeof(ARKitXRPlaneRemoteSubsystem),
                supportsHorizontalPlaneDetection = true,
                supportsVerticalPlaneDetection   = true,
                supportsArbitraryPlaneDetection  = false,
                supportsBoundaryVertices         = true,
                supportsClassification           = true,
            };

            XRPlaneSubsystemDescriptor.Create(cinfo);
            Debug.LogFormat("Registered the {0} subsystem", id);
#endif
        }
コード例 #7
0
        static void RegisterDescriptor()
        {
            XRPlaneSubsystemDescriptor.Create(new XRPlaneSubsystemDescriptor.Cinfo
            {
                id = "MARS-Plane",
#if ARSUBSYSTEMS_4_OR_NEWER && UNITY_2020_2_OR_NEWER
                providerType          = typeof(PlaneSubsystem.MARSXRProvider),
                subsystemTypeOverride = typeof(PlaneSubsystem),
#else
                subsystemImplementationType = typeof(PlaneSubsystem),
#endif
                supportsHorizontalPlaneDetection = true,
                supportsVerticalPlaneDetection   = true,
                supportsArbitraryPlaneDetection  = true,
                supportsBoundaryVertices         = true,
#if ARSUBSYSTEMS_3_OR_NEWER
                supportsClassification = false,
#endif
            });
        }