Input forwarding
Updated: Oct 7, 2025
Input forwarding eliminates the need to constantly put on and take off your headset during development. Move around your scene, click and drag on panels, and grab objects in your 3D scene using keyboard and mouse controls.
Here’s a quick example of what input forwarding looks like in action:
You need Meta Quest Developer Hub (MQDH) version 5.0 or later to use input forwarding.
Download MQDH to get started. Input forwarding works through MQDH’s cast functionality.
Sample projects already include this setup.
In the [versions] block of your libs.versions.toml file, add a variable called spatialSDK if there isn’t one already.
In the [libraries] block, add the cast input forward feature.
meta-spatial-sdk-castinputforward = { group = "com.meta.spatial", name = "meta-spatial-sdk-castinputforward", version.ref = "spatialsdk" }
In the dependencies {} block of app/build.gradle.kts, add the new dependency.
dependencies {
implementation(libs.meta.spatial.sdk.castinputforward)
}
In your app’s main activity file, add the CastInputForwardFeature to the registerFeatures() method.
override fun registerFeatures(): List<SpatialFeature> {
var features = ...
if (BuildConfig.DEBUG) {
features.add(CastInputForwardFeature(this))
}
return features
}
CastInputForwardFeature should never be included in release builds. The BuildConfig.DEBUG check ensures this feature only runs during development.
Connect your headset
Make sure it shows up in MQDH.
Start casting with MQDH
Run your app
Make sure that you’re building a DEBUG flavor, and run your app in Android Studio.
Select the input forwarding icon while inside of your app to enable input forwarding.
Casting with input forwarding only works with your resolution set to Original (1:1). It will not work correctly if your resolution is set to Cropped (16:9) or Cinematic (16:9).
Note: The white cursor reflects the input forwarding controller’s interaction with the scene. This may not line up perfectly with where your mouse cursor is on the Cast window.
| Key | Action |
|---|
W / Up Arrow | Move forward |
S / Down Arrow | Move backward |
A | Move left |
D | Move right |
Q | Move up |
E | Move down |
Left Arrow | Rotate left |
Right Arrow | Rotate right |
Shift | Sprint |
Left mouse button | Click |
Ctrl + Left mouse button / Right mouse button | Hold to rotate view |
Space + Left mouse button | Grab |
Verify the following:
- You are on MQDH version 5.0
- You have followed all the steps to include input forwarding to your app.
- It must be added per-app.
CastInputForwardFeature should be one of the features you return in registerFeatures()
Your app is in general input forwarding mode if you experience slow movement, can leave the boundary, and see no input forwarding cursor. Spatial SDK needs a specific input forwarding mode to connect to your cast window.
Fix this by restarting your app and selecting the input forward icon in your Cast window again. In rare cases you may need to restart your Cast window as well.
Make sure you have added the
<uses-native-library> tag for
libossdk, mentioned above in the
Adding input forwarding section.