# 6. Quest 2 Input Hands and Passthrough Part of [[Meta Quest 2]]. Requires Unity 6.3 LTS (6000.3.27f2) and newer. Previous: [[5.Quest 2 Performance and Rendering]]. Next: [[7.Quest 2 Worked Example Room]]. > [!important] Version requirement > Unity 6.3 LTS (6000.3.27f2) and newer. XR Hands: 6000.3 installs 1.7.3 by default; use **1.8.1 or newer** from Package Manager's version list. ## 6.1 Controllers With OpenXR, add the **Oculus Touch Controller Profile** in **Project Settings > XR Plug-in Management > OpenXR > Interaction Profiles** (Android tab). XRI's starter input actions map Touch controllers for you. Store guidance: use **grip** to pick up objects (VRC.Quest.Input.2, recommended), and the left controller **menu** button for in-game menus (VRC.Quest.Input.1, recommended) ([VRC list](https://developers.meta.com/horizon/resources/publish-quest-req/)). ## 6.2 Hand tracking There are two routes, matching [[2.Quest 2 SDK Stack]]: | Route | Setup | |---|---| | **OpenXR + XR Hands** | Install XR Hands. In OpenXR Features enable **Hand Tracking Subsystem** and **Meta Hand Tracking Aim**. Requires OpenXR 1.6+ per the XR Hands docs ([Meta Aim Hand feature](https://docs.unity3d.com/Packages/[email protected]/manual/features/metahandtrackingaim.html)). Add hand visualizer/interactor samples from the XRI and XR Hands packages. | | **Meta XR SDK** | OVR Manager > Quest Features > **Hand Tracking Support = Controllers and Hands**, then `OVRHandPrefab` under each hand anchor ([Meta hand setup](https://developers.meta.com/vr/documentation/unity/unity-handtracking-hands-setup/)). | **Simultaneous hands and controllers (multimodal).** Meta's multimodal input page describes OVR Manager > Quest Features > **Simultaneous Hands And Controllers = Supported/Required** ([Meta multimodal](https://developers.meta.com/horizon/documentation/unity/unity-multimodal/)). Whether every multimodal option works on Quest 2 specifically is **(unverified)**. **Store rules if you support hands:** respect controller/hand switches (VRC.Quest.Input.7, required) and do not trigger actions with the reserved system gesture (VRC.Quest.Input.8, required). ### Inline script: hand tracking status probe Drop this on any object to see on the log (and in the panel in [[7.Quest 2 Worked Example Room]]) whether hands are active. It uses `XRHandSubsystem` from XR Hands. ```csharp using System.Collections.Generic; using UnityEngine; using UnityEngine.XR.Hands; /// <summary> /// Reports whether the XR Hands subsystem is running and which hands are tracked. /// Not compiled in an editor. /// </summary> public class HandTrackingProbe : MonoBehaviour { [SerializeField] float pollSeconds = 0.5f; public static bool SubsystemRunning { get; private set; } public static bool LeftTracked { get; private set; } public static bool RightTracked { get; private set; } readonly List<XRHandSubsystem> subsystems = new(); float nextPoll; void Update() { if (Time.unscaledTime < nextPoll) return; nextPoll = Time.unscaledTime + pollSeconds; subsystems.Clear(); SubsystemManager.GetSubsystems(subsystems); SubsystemRunning = false; LeftTracked = false; RightTracked = false; foreach (var hands in subsystems) { if (!hands.running) continue; SubsystemRunning = true; LeftTracked |= hands.leftHand.isTracked; RightTracked |= hands.rightHand.isTracked; } } } ``` ## 6.3 Passthrough and mixed reality on Quest 2 Passthrough on Quest 2 is much more limited than on Quest 3. | Capability | Quest 2 | |---|---| | Passthrough | **Black and white (grayscale)**, low resolution, monoscopic; objects close to the headset look distorted | | Color passthrough | **No** (`OVRManager.GetPassthroughCapabilities().SupportsColorPassthrough` is false) | | Depth API / occlusion | **No** | | Scene mesh / room model, plane detection | **No** (Quest 3 / 3S) **(unverified for each; consult the Meta MR docs)** | Sources: [Meta color passthrough docs](https://developers.meta.com/horizon/documentation/unity/unity-passthrough-color-mapping/), and a Unity forum thread on Quest 3 passthrough features not coming to Quest 2 ([forum](https://discussions.unity.com/t/quest-3-passthrough-support-backport-to-quest-2/943973)). ### How to enable passthrough | Path | Steps | |---|---| | Unity OpenXR: Meta | Enable the **Meta Quest Camera (Passthrough)** feature; use Unity's MR/AR Foundation templates; set the camera's clear flags to a transparent background. | | Meta XR SDK | Add `OVRPassthroughLayer` (Building Blocks has a Passthrough block); set `OVRManager.isInsightPassthroughEnabled`. | Use passthrough as **a comfort feature on Quest 2** (see your room while setting up a play area, an MR "lite" background) and not as a full MR product. If you need color or occlusion, target Quest 3. ### Inline script: capability check (needs Meta XR Core SDK) Add this file **only if** you installed the Meta XR Core SDK, otherwise it will not compile. It lets you hide color-dependent features on Quest 2. ```csharp using UnityEngine; /// <summary> /// Logs passthrough capabilities. Requires Meta XR Core SDK (OVRManager). /// Not compiled in an editor. /// </summary> public class PassthroughCapabilityCheck : MonoBehaviour { public static bool SupportsColor { get; private set; } void Start() { SupportsColor = OVRManager.GetPassthroughCapabilities().SupportsColorPassthrough; Debug.Log(quot;[Passthrough] color supported: {SupportsColor}"); if (!SupportsColor) { Debug.Log("[Passthrough] grayscale passthrough only (expected on Quest 2)."); } } } ``` ## Official references - [Unity: XR Hands](https://docs.unity3d.com/6000.3/Documentation/Manual/com.unity.xr.hands.html) - [Meta: Hand tracking setup](https://developers.meta.com/vr/documentation/unity/unity-handtracking-hands-setup/) - [Meta: Passthrough color mapping](https://developers.meta.com/horizon/documentation/unity/unity-passthrough-color-mapping/) Next: [[7.Quest 2 Worked Example Room]]