Porting your MRTK-based HoloLens 2 application to Magic Leap 2 requires only a few adjustments to your Unity project environment. Using the Magic Leap 2 Unity SDK and MRTK Magic Leap 2 plugin according to this guide will get your project running on the Magic Leap 2 with minimal effort.
The MRTK Magic Leap 2 plugin currently only supports MRTK v2.8.
There are several key differences between the HoloLens 2 and Magic Leap 2 MRTK development environment:
|HoloLens 2||Magic Leap 2|
|Unity editor version||2021.3 LTS||2022.2.x or newer|
|Render Pipeline||Lightweight Render Pipeline||Universal Render Pipeline|
|Build Target||Universal Windows Platform||Android|
|Interaction method||Hand tracking||Controller, Hand tracking|
|XR Plugin Managment||OpenXR||Magic Leap|
MRTK Feature Support
|HoloLens 2||Magic Leap 2|
- Your project must use Microsoft MRTK v2.8
- You have downloaded and installed the latest compatible versions of the Magic Leap Unity SDK, MRTK Magic Leap 2 package, and Unity editor as outlined in the guides below.
- If your project uses the Hololens System keyboard, you will need to replace the system keyboard calls with MRTK's
Update your Unity Project for Magic Leap 2
Part 1: Update and configure your Unity project settings
- Update your Unity editor version to 2022.2.0b7 or higher.
- Download and install the latest compatible versions of the Magic Leap OS and Magic Leap SDK (v1.1.0-dev1 or newer). Use this compatibility matrix to check version compatibility.
- Open your Unity project in the new version of the Unity editor and complete the steps in the Configure Project Settings Unity guide.
- Follow the Render Pipeline Settings Unity guide to change your render pipeline settings to the Universal Render Pipeline.
Part 2: Implement the MRTK - Magic Leap 2 plugin
- Follow the Set Up MRTK for Magic Leap 2 guide to configure MRTK to work with the MRTK Magic Leap 2 plugin.
Part 3: Taking Advantage of Magic Leap 2 Features
An often-overlooked input modality, the Controller offers interaction options beyond standard HandTracking. Usage of a Controller in an AR application can lead to better end-user comfort over a longer period of time, eliminating the fatigue of a typical hand-tracking-exclusive application.
With an increased horizontal and vastly-expanded vertical field of view, an AR app benefits by being able to see human-sized virtual content from just a few feet away. Moving from the Hololens 2 to a Magic Leap 2, the difference will be noticeable immediately.
The Magic Leap 2 uses an
x86_64-based architecture, with processors that are able to compute far more complex geometry, shaders, and textures at smoother framerates than previous-generation AR devices.