Search Unity

Errors with AR Foundation

Discussion in 'AR' started by Cengi, Jan 21, 2020.

  1. Cengi

    Cengi

    Joined:
    Mar 26, 2019
    Posts:
    1
    I've been playing around with the AR Foundation samples on GitHub. I cloned the master branch and it uses 2019.2.x, so I opened the project in that version of Unity.

    I am interested in testing the image tracking scene on both an Android device and on a Magic Leap. Even though I got it running on Android, I have been struggling to get the same scene to build for Magic Leap. I've been able to follow most of the Unity Project Setup steps, except for:
    • XR Plugin Management: In Project Settings > XR Plugin Management I can't seem to select a tab for the platform. This prevents me from installing the Magic Leap Loader.
    • AR Foundation: For some reason I cannot find the Magic Leap XR Support package when searching in Package Manager. When I force it to install through the project's manifest.json I end up with a plethora of errors. Some trial and error has shown me that the AR Foundation 3.x packages is the culprit. Does this mean I cannot use both the AR Foundation preview.3-3.1.0 (or any 3.x version as far as I can tell) and the Magic Leap XR Support packages at the same time?
    I watched the Product roadmap for AR Foundation - Unite Copenhagen some time ago and it states that from Unity 2019.3 AR Foundation should support Magic Leap as well, so for good measure I did upgrade the project to 2019.3 and tried to follow the Unity Project Setup steps again. Sadly, the same problems still persist: This time, in Project Settings > XR Plugin Management the tabs and the Magic Leap XR plugin do show up now, but it never successfully installs. The packages installed are:
    • AR Foundation preview.3 - 3.1.0
    • AR Subsystems preview.2 - 3.1.0
    • ARCore XR Plugin preview.2 - 3.1.0
    • ARKit XR Plugin preview.2 - 3.1.0
    • XR Legacy Input Helpers 2.0.6
    • XR Management preview.2 - 3.1.0
    If anyone is interested in Console errors, you can find them here:

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Raycasting\MagicLeapRaycastSubsystem.cs(60,34): error CS0115: 'MagicLeapRaycastSubsystem.Provider.Start()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Raycasting\MagicLeapRaycastSubsystem.cs(33,38): error CS0508: 'MagicLeapRaycastSubsystem.CreateProvider()': return type must be 'XRRaycastSubsystem.Provider' to match overridden member 'XRRaycastSubsystem.CreateProvider()'

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Raycasting\MagicLeapRaycastSubsystem.cs(39,26): error CS0246: The type or namespace name 'IProvider' could not be found (are you missing a using directive or an assembly reference?)

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Raycasting\MagicLeapRaycastSubsystem.cs(60,34): error CS0115: 'MagicLeapRaycastSubsystem.Provider.Start()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Raycasting\MagicLeapRaycastSubsystem.cs(69,34): error CS0115: 'MagicLeapRaycastSubsystem.Provider.Stop()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Raycasting\MagicLeapRaycastSubsystem.cs(78,34): error CS0115: 'MagicLeapRaycastSubsystem.Provider.Destroy()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(43,28): error CS0246: The type or namespace name 'IProvider' could not be found (are you missing a using directive or an assembly reference?)

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(43,38): error CS0508: 'MagicLeapPlaneSubsystem.CreateProvider()': return type must be 'XRPlaneSubsystem.Provider' to match overridden member 'XRPlaneSubsystem.CreateProvider()'

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(76,28): error CS0246: The type or namespace name 'IProvider' could not be found (are you missing a using directive or an assembly reference?)

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(76,38): error CS0508: 'MagicLeapReferencePointSubsystem.CreateProvider()': return type must be 'XRAnchorSubsystem.Provider' to match overridden member 'XRAnchorSubsystem.CreateProvider()'

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(55,26): error CS0246: The type or namespace name 'IProvider' could not be found (are you missing a using directive or an assembly reference?)

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(84,48): error CS0115: 'MagicLeapPlaneSubsystem.Provider.planeDetectionMode': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(96,34): error CS0115: 'MagicLeapPlaneSubsystem.Provider.Start()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(117,34): error CS0115: 'MagicLeapPlaneSubsystem.Provider.Stop()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(134,34): error CS0115: 'MagicLeapPlaneSubsystem.Provider.Destroy()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(163,41): error CS0115: 'MagicLeapPlaneSubsystem.Provider.GetBoundary(TrackableId, Allocator, ref NativeArray<Vector2>)': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Plane\MagicLeapPlaneSubsystem.cs(182,67): error CS0115: 'MagicLeapPlaneSubsystem.Provider.GetChanges(BoundedPlane, Allocator)': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(81,26): error CS0246: The type or namespace name 'IProvider' could not be found (are you missing a using directive or an assembly reference?)

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(115,34): error CS0115: 'MagicLeapReferencePointSubsystem.Provider.Start()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(131,34): error CS0115: 'MagicLeapReferencePointSubsystem.Provider.Stop()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(140,34): error CS0115: 'MagicLeapReferencePointSubsystem.Provider.Destroy()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(285,63): error CS0115: 'MagicLeapReferencePointSubsystem.Provider.GetChanges(XRAnchor, Allocator)': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(305,41): error CS0115: 'MagicLeapReferencePointSubsystem.Provider.TryAddReferencePoint(Pose, out XRAnchor)': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\ReferencePoint\MagicLeapReferencePointSubsystem.cs(373,34): error CS0115: 'MagicLeapReferencePointSubsystem.Provider.TryRemoveReferencePoint(TrackableId)': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Session\MagicLeapSessionSubsystem.cs(14,28): error CS0246: The type or namespace name 'IProvider' could not be found (are you missing a using directive or an assembly reference?)

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Session\MagicLeapSessionSubsystem.cs(14,38): error CS0508: 'MagicLeapSessionSubsystem.CreateProvider()': return type must be 'XRSessionSubsystem.Provider' to match overridden member 'XRSessionSubsystem.CreateProvider()'

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Session\MagicLeapSessionSubsystem.cs(19,26): error CS0246: The type or namespace name 'IProvider' could not be found (are you missing a using directive or an assembly reference?)

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Session\MagicLeapSessionSubsystem.cs(28,58): error CS0115: 'MagicLeapSessionSubsystem.Provider.GetAvailabilityAsync()': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Session\MagicLeapSessionSubsystem.cs(39,43): error CS0115: 'MagicLeapSessionSubsystem.Provider.trackingState': no suitable method found to override

    Library\PackageCache\com.unity.xr.magicleap@4.0.5\Runtime\Session\MagicLeapSessionSubsystem.cs(60,34): error CS0115: 'MagicLeapSessionSubsystem.Provider.Destroy()': no suitable method found to override

    If anyone could explain to me why I cannot get it work, it would be of great help. Thanks in advance!
     
  2. MrMatthias

    MrMatthias

    Joined:
    Sep 18, 2012
    Posts:
    191
    It's not compatible. Currently i switch out package manifest files when switching platforms
     
    vincentpaolo likes this.
  3. francopenizzotto

    francopenizzotto

    Joined:
    Feb 2, 2020
    Posts:
    5
    @Cengi, I have the same issue. Please, let me know if you can solve it.
     
    vincentpaolo likes this.