Gitpedia

Metal spatial rendering

A minimal example of rendering an immersive spatial experience with Metal, ARKit, and visionOS Compositing Services

From metal-by-example·Updated May 25, 2026·View on GitHub·

This sample is a minimal example of rendering a immersive spatial experience with Metal, ARKit, and visionOS Compositing Services. The project is written primarily in Objective-C++, distributed under the The Unlicense license, first published in 2023. Key topics include: 3d-graphics, metal, objective-c-plus-plus, spatial-computing, swiftui.

Immersive Spatial Rendering with Metal in visionOS

This sample is a minimal example of rendering a immersive spatial experience with Metal, ARKit, and visionOS Compositing Services.

Example screenshot of spatial rendering

When running on the Simulator, the app uses the .dedicated layout. When running on an Apple Vision Pro, the app uses the .layered layout along with Metal vertex amplification to efficiently render both stereo views in a single pass.

When running on a visionOS 2 simulator or device, the app enables the mixed immersion style and enables the user to progressively select how much of the real world is visible via passthrough.

Contributors

Showing top 4 contributors by commit count.

View all contributors on GitHub →

This article is auto-generated from metal-by-example/metal-spatial-rendering via the GitHub API.Last fetched: 6/1/2026