AR Foundation Replay
March 24, 2026 ยท View on GitHub
๐ง Work in progress ๐๏ธ
PoC of Recording AR Foundation session into a single mp4 with a binary timeline track / Replaying it in Editor on AR Foundation without any extra settings.
https://github.com/asus4/ARFoundationReplay/assets/357497/8e77ee45-6f2c-442e-a47a-f35f044b8181
โ Check out the complete project utilizing ARFoundationReplay.
https://github.com/asus4/WorldEnsemble/assets/357497/1ff03fd4-01cf-41a6-8aef-42e11f7a67a2
Tested platform
- Only iOS ARKit + macOS Editor for now. Android ARCore is planned.
- Tested with the latest Unity6 LTS.
- Supported only URP. Built-in is not supported for now.
Implemented Subsystems
- XRSessionSubsystem
- XRCameraSubsystem
- XRPointCloudSubsystem
- XRPlaneSubsystem
- XRAnchorSubsystem
- XRRaycastSubsystem
- XRHumanBodySubsystem
- XREnvironmentProbeSubsystem
- XRInputSubsystem
- XRImageTrackingSubsystem
- XRObjectTrackingSubsystem
- XRFaceSubsystem
- XROcclusionSubsystem
- XRParticipantSubsystem
- XRMeshSubsystem
- ARCore Extensions
- Earth Manager
- Streetscape Geometry
How to use
-
Install MemoryPack from NuGet using NuGetForUnity
openupm add com.github-glitchenzo.nugetforunity- Open Window from NuGet -> Manage NuGet Packages, Search "MemoryPack" and Press Install.
-
Add the following line to
Packages/manifest.jsonto install AR Foundation Replay package via UPM:"dependencies": { "com.github.asus4.arfoundationreplay": "https://github.com/asus4/ARFoundationReplay.git?path=Packages/com.github.asus4.arfoundationreplay#v0.4.2", ... other dependencies } -
Simulation on the Unity Editor is supported only on iOS. Open Build Settings and switch the platform to iOS.
-
Activate AR Foundation Replay for Unity Editor:
- Open
Project Settings/XR Plug-in Management. - Select the PC tab in the XR Plug-in Management.
- Activate
AR Foundation Replay
- Open
-
Put the ARRecordButton prefab into the Scene which is located at
Packages/com.github.asus4.arfoundationreplay/Prefabs/ARRecordButton.prefab. -
Record AR on the device and send it to the Unity Editor.
- An example video is available on the Release page
-
You can change the replay file from
Project Settings/XR Plug-in Management/AR Foundation Replay. -
Play the AR in the Editor.
ARCore Extensions Support
It supports replaying ARCore Geospatial. To test it, please use the forked version of the arcore-unity-extensions and refer to the ARFoundationReplayGeospatial example project.
Dependencies
- MemoryPack - MIT License
- XR SDK - Unity Companion License
- keijiro/Bibcam - Unlicense
- keijiro/Avfi - Unlicense: Metadata recording system is modified from Avfi.