Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Adds Android XR depth backend#1373

Open
austinbhale wants to merge 6 commits into
StereoKit:developStereoKit/StereoKit:developfrom
Nakamir-Code:feature/android-depth-textureNakamir-Code/StereoKit:feature/android-depth-textureCopy head branch name to clipboard
Open

Adds Android XR depth backend#1373
austinbhale wants to merge 6 commits into
StereoKit:developStereoKit/StereoKit:developfrom
Nakamir-Code:feature/android-depth-textureNakamir-Code/StereoKit:feature/android-depth-textureCopy head branch name to clipboard

Conversation

@austinbhale

@austinbhale austinbhale commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Adds XR_ANDROID_depth_texture as a native depth backend so Sensor.Depth and depth-based World.Occlusion work on Android XR behind the existing public API.

Unlike Meta's GPU swapchain (NDC d16), the Android extension delivers CPU float arrays in metric meters. A new sensor_depth_format_ field (ndc_d16 vs meters_r32) lets each backend expose its native format.

  • CPU-direct vs GPU readback. Meta serves a GPU texture through the readback; Android serves CPU buffers directly. sensor_depth_try_get_latest_data is now provider-aware, and the C# TryGetLatestData has a texture-less path.
  • Occlusion. Added a depth_format-gated path that reconstructs per-eye from fov tangents + pose.

Public API changes

  • Permission: permission_type_scene_fine (SCENE_UNDERSTANDING_FINE)
  • Enums: sensor_depth_format_ (ndc_d16/meters_r32), sensor_depth_image_; new sensor_depth_caps_ flags (raw / smooth / confidence)
  • sensor_depth_frame_t fields: depth_format, view_count, available_images
  • Signature changes: sensor_depth_start gains a resolution; sensor_depth_try_get_latest_data gains an image selector
  • New: sensor_depth_get_resolutions
  • C# mirrors all of the above (SensorDepthFormat/Image, caps flags, Sensor.Depth.Start(resolution), GetResolutions(), TryGetLatestData(..., image))

Testing

  • Meta impl has no regressions
  • XREAL Aura (raw + smooth, confidence coloring, and depth occlusion)
  • Galaxy XR (same as above, can verify tomorrow)

@austinbhale
austinbhale marked this pull request as ready for review June 26, 2026 02:51
Signed-off-by: Austin Hale <ahale@nakamir.com>
Signed-off-by: Austin Hale <ahale@nakamir.com>
Signed-off-by: Austin Hale <ahale@nakamir.com>
@austinbhale
austinbhale force-pushed the feature/android-depth-texture branch from 4560f8e to 0dafc0c Compare June 26, 2026 02:54
Signed-off-by: Austin Hale <ahale@nakamir.com>
Signed-off-by: Austin Hale <ahale@nakamir.com>
@austinbhale
austinbhale force-pushed the feature/android-depth-texture branch from 2d5e79e to 9bc46fc Compare July 14, 2026 05:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

Morty Proxy This is a proxified and sanitized view of the page, visit original site.