# Magic Leap, Unity, Vuforia Setup

**URL:** <https://forum.magicleap.cloud/t/magic-leap-unity-vuforia-setup/4357>\
**Category:** Unity Development\
**Tags:** development, unity, ml-hub, vuforia, openxr\
**Created:** [October 2, 2024, 4:06pm UTC](https://forum.magicleap.cloud/t/magic-leap-unity-vuforia-setup/4357 "2024-10-02T16:06:48Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![lok.l.fung](https://avatars.discourse-cdn.com/v4/letter/l/b9bd4f/32.png) [@lok.l.fung](https://forum.magicleap.cloud/u/lok.l.fung)\
**Post date:** [October 2, 2024, 4:06pm UTC](https://forum.magicleap.cloud/t/magic-leap-unity-vuforia-setup/4357/1 "2024-10-02T16:06:48Z")

</div>

Hello,

I'm following this guide to install the tools to operate a Magic Leap 2 using Vuforia via Unity OpenXR:

> **[Install the Tools | MagicLeap Developer Documentation](https://developer-docs.magicleap.cloud/docs/guides/unity-openxr/getting-started/install-the-tools/)**
>
> This section provides information on how to install and configure the Unity Editor required to develop for Magic Leap 2.

However, I immediately run into a problem obtaining the ML C SDK, where the ML Hub 3 cannot download the zip file required for the install, returning "Reason: Aborted". Interestingly, I am able to manually download this file from the link below:

[https://thelab.magicleap.cloud/packages\_mlhub/artifacts/com.magicleap.lumin.sdk/1.9.0/mlsdk\_public\_win.zip](https://thelab.magicleap.cloud/packages_mlhub/artifacts/com.magicleap.lumin.sdk/1.9.0/mlsdk_public_win.zip)

There is no clear way to install it in a manner where it will be recognized as a dependency by the Unity Package. Is there a way to install this manually, or is there a reason the file download is being aborted? I am able to install all other items from the Package manager, but the ML C SDK is for some reason, an exception.

I am also reading in some places that the ML C SDK is an optional dependency, but see no method to download the Unity Package without requiring completion of the ML C SDK installation.

Once the ML C SDK and Unity Package are installed, I assume one of these directories must be targeted by step 5.1 from this guide to set up Vuforia in Unity for the Magic Leap 2, but it is not clear which:

> **[Configure Project Settings | MagicLeap Developer Documentation](https://developer-docs.magicleap.cloud/docs/guides/unity/getting-started/configure-unity-settings/)**
>
> This topic describes how to configure the Unity Build Settings to utilize Magic Leap features.

I am running on a Windows, ML Hub 3, Unity 2022.3.48f1.

Any help would be appreciated.

---

<div class="post-metadata">

**Author:** ![kbabilinski](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.magicleap.cloud/kbabilinski/32/19_2.png) [@kbabilinski](https://forum.magicleap.cloud/u/kbabilinski)\
**Post date:** [October 2, 2024, 4:22pm UTC](https://forum.magicleap.cloud/t/magic-leap-unity-vuforia-setup/4357/2 "2024-10-02T16:22:16Z")

</div>

I let our ML Hub team know of the issue. In the meantime you can download the pre-configured Unity Example project from GitHub:

> **[GitHub - magicleap/MagicLeapUnityExamples: This project contains Examples for the Magic Leap...](https://github.com/magicleap/MagicLeapUnityExamples)**
>
> This project contains Examples for the Magic Leap Unity SDK and has been configured so developers can start developing for the Magic Leap platform quickly.

* * *

We are currently tracking a bug where the Magic Leap Unity Package is not visible in the package manager even with the Registry is added.

> **[Configure Project Settings | MagicLeap Developer Documentation](https://developer-docs.magicleap.cloud/docs/guides/unity-openxr/getting-started/configure-unity-settings/#manual-setup)**
>
> This section provides detailed steps on how to manually configure your Unity Project so that you can build and deploy OpenXR applications for Magic Leap 2.

* * *

Lastly, we have had users report issues using Vuforia with the OpenXR version of the Magic Leap SDK and Unity. If you choose to use the MLSDK version of the example project, you can try to download version 1.12.0 of the Unity Examples from the Magic Leap Hub or download the 1.12.0 branch from GitHub.

---

<div class="post-metadata">

**Author:** ![martin.wilter](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.magicleap.cloud/martin.wilter/32/444_2.png) [@martin.wilter](https://forum.magicleap.cloud/u/martin.wilter)\
**Post date:** [October 12, 2024, 7:51pm UTC](https://forum.magicleap.cloud/t/magic-leap-unity-vuforia-setup/4357/3 "2024-10-12T19:51:45Z")

</div>

> [@kbabilinski](#):
>
> Lastly, we have had users report issues using Vuforia with the OpenXR version of the Magic Leap SDK and Unity.

Hi @kbabilinski, would you be able to share more details on the reported issues?

We are porting our app from UWP and about to start on the Vuforia part. Using Unity 2022.3.45 and OpenXR. We are currently using Unity SDK 2.0.0, due newer versions being incompatible with the Unity Transport version we are using, but expect to update to Unity SDK 2.4.0 next week.

---

<div class="post-metadata">

**Author:** ![kbabilinski](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.magicleap.cloud/kbabilinski/32/19_2.png) [@kbabilinski](https://forum.magicleap.cloud/u/kbabilinski)\
**Post date:** [October 14, 2024, 3:28pm UTC](https://forum.magicleap.cloud/t/magic-leap-unity-vuforia-setup/4357/4 "2024-10-14T15:28:06Z")

</div>

The main issue seems to be related to tracking objects properly. While some users have successfully used OpenXR, I don’t have all the specifics on the steps they took.

If you're working with OpenXR, make sure to enable **Perception Snapshots** by going to **OpenXR Settings \> Magic Leap Support \> Enable Perception Snapshots**.

Additionally, you may need to adjust your **tracking reference space** to **unbounded** to ensure that the Camera Pose aligns with the XR Rig.

> **[Additional Features | MagicLeap Developer Documentation](https://developer-docs.magicleap.cloud/docs/guides/unity-openxr/additional-features/#enabling-perception-snapshots)**
>
> Overview

---

<div class="post-metadata">

**Author:** ![lok.l.fung](https://avatars.discourse-cdn.com/v4/letter/l/b9bd4f/32.png) [@lok.l.fung](https://forum.magicleap.cloud/u/lok.l.fung)\
**Post date:** [October 17, 2024, 7:54pm UTC](https://forum.magicleap.cloud/t/magic-leap-unity-vuforia-setup/4357/5 "2024-10-17T19:54:21Z")

</div>

If the package requires a registry entry at all, that could be why this not working. Many security solutions prohibit access to the windows registry.

---

<div class="post-metadata">

**Author:** ![lok.l.fung](https://avatars.discourse-cdn.com/v4/letter/l/b9bd4f/32.png) [@lok.l.fung](https://forum.magicleap.cloud/u/lok.l.fung)\
**Post date:** [October 17, 2024, 9:46pm UTC](https://forum.magicleap.cloud/t/magic-leap-unity-vuforia-setup/4357/6 "2024-10-17T21:46:29Z")

</div>

Getting the following issue with the Unity Examples:

"Gradle build failed."

- What went wrong:  
Plugin [id: 'com.android.application', version: '7.4.2', apply: false] was not found in any of the following sources:

The Gradle version that we're using is 7.5.1, but changing the version in build.gradle to 7.5.1 yields the same error.
