Search Unity

he type or namespace name 'SpatialTracking' does not exist in the namespace 'UnityEngine' (are you m

Discussion in 'ARCore' started by CrocsxG, Mar 26, 2019.

  1. CrocsxG

    CrocsxG

    Joined:
    Jan 2, 2018
    Posts:
    2
    I am using latest unity 2018.3.10f1 and I have the following error in google SDK AR CORE.
    There is similar issue on the internet, all say that updating unity would fix the issue, but since I have the latest option, I wanted to know if there is a fix ?

    I have commented out the function that need this feature (cause I do not use it) but if you have any clue.

    thanks
     
  2. tdmowrer

    tdmowrer

    Unity Technologies

    Joined:
    Apr 21, 2017
    Posts:
    547
    I just opened https://github.com/google-ar/arcore-unity-sdk in Unity 2018.3.10f1 without any errors. Do you have the latest ARCore SDK for Unity? If so, can you paste the full error message here?
     
  3. Fattie

    Fattie

    Joined:
    Jul 5, 2012
    Posts:
    411
    I found that simply UPDATING EVERYTHING IN PACKAGE MANAGER seems to fix this problem.
     
    bowserscastle likes this.
  4. tdmowrer

    tdmowrer

    Unity Technologies

    Joined:
    Apr 21, 2017
    Posts:
    547
    Just to clarify for future readers of this thread: OP mentions using "google SDK AR CORE", which is a plugin provided by Google.

    However, "UPDATING EVERYTHING IN PACKAGE MANAGER" suggests you are using ARFoundation, which is different. ARFoundation 1.0 is only compatible with Unity 2018.3. Unity 2019.1+ requires ARFoundation 1.1, which resolves the compilation errors related to
    UnityEngine.SpatialTracking
    .
     
    ethqnit, BVGuled, TomKhan3 and 3 others like this.
  5. Fattie

    Fattie

    Joined:
    Jul 5, 2012
    Posts:
    411
    Quite right, @tdmowrer sorry to add to the confusion.

    In my case I was using Unity's current (I think only?) AR sample project: https://github.com/Unity-Technologies/arfoundation-samples

    In a word, if you "download that and try it" at the moment, (it has not been updated in a long time) you get the same error as in this question; if you google there's a pile of QA about it. Indeed simply "updating everything" fortunately fixes the problem with /arfoundation-samples. Thanks.
     
    TheKingOfTheRoad likes this.
  6. dormouse

    dormouse

    Joined:
    Mar 1, 2011
    Posts:
    65
    I got the same errors after upgrading Unity3D to 2019.2.0f1 using Unity Hub.
    in the attach, you can find all errors after importing ARCore SDK 1.10.
    Please help us to find a solution. thanks
     

    Attached Files:

  7. hiachrism

    hiachrism

    Joined:
    Aug 16, 2019
    Posts:
    4
    The majority of those errors are because the Unity Multiplayer HLAPI package is missing. High-level networking is no longer included by default for new projects.

    There will likely be one remaining issue due to SpatialTracking namespace not being available where TrackedPoseDriver lived before; that one I haven't tracked down yet and am just backing down to 2018.3 to get started for now.

    Edit: Nevermind, according to the newer instructions for ARCore setup for Unity 2019, it now requires addition of HLAPI package as well as the XR Legacy Input Helper in Package Manager. Guessing that will resolve most if not all errors using ARCore in 2019.2 projects.