<aside> ⚠️
This page is synced from GitHub. Edits will be overwritten.
Source: https://github.com/uwrealitylabs/standalone-knowledge-base/blob/main/docs/standalone-driver/emulation/Mock capture.md
Last synced: 2026-11-01 23:20:30 UTC
</aside>
Part of Project Standalone. Compare EuRoC player.
Source: branch mock-camera-input of uwrealitylabs/standalone-monado-driver, single commit 9363dbe (2026-10-29) on top of dev at 3400e2f. All code is under tests/standalone-camera-mock/; paths below are relative to that folder. Nothing under src/xrt/ changes and the builder (target_builder_standalone.c) is untouched.
Per its README, the run was validated on Apple Silicon macOS (2026-10-28). Independent reproduction by a teammate, Linux/RB5 runs, and confirmation of the receiving interface are still pending.
A synthetic camera source plus a test harness:
xrt_fs frame server (see Sinks) that generates images on a producer thread and pushes them into whatever sinks it is started with.It does not create a builder, device, tracker (t_slam, Basalt, Mercury), service, compositor or OpenXR app.
| Package | Contents | Built from |
|---|---|---|
capture_mock/ |
The source (native/mock_capture.cpp, .h), an original single-camera harness, fixtures, Python bindings and runner |
Own CMake project; compiles Monado's u_sink_queue.c directly |
pipeline_matrix/ |
Test graph: optional format converter, optional force-genlock pairing, queue, observer | Compiles u_sink_converter.c, u_sink_force_genlock.c, u_frame.c, u_format.c directly |
capture_e2e/ |
Joins the source to the graph through a per-camera "guard" sink (native/session.cpp) and orchestrates end-to-end scenarios |
Links the two above |
Entry point: run.py (full suite, or --scenario four-l8 / four-rgb). Python 3.13, OpenCV via capture_mock/requirements.lock. reviewed-sources.json records hashes of the upstream Monado files it compiles and refuses to run if any changed.
API in capture_mock/native/mock_capture.h:
| Function | Behaviour |
|---|---|
wrl_mock_capture_create(_format)(xfctx, &config [, format]) |
One camera. Implements stream_start into one sink; slam_stream_start returns NOT_IMPLEMENTED (mock_capture.cpp:111) |
wrl_mock_capture_group_create(_format)(xfctx, configs, n [, format]) |
1–4 cameras behind one xrt_fs. slam_stream_start routes configs[i] to sinks.cams[i] (:257, :276) |
wrl_mock_capture_group_schedule, _group_stats |
Set the shared start time; read per-camera counters |
Frames (make_frame, :150):
xrt_frame with its own pixel buffer and refcount; destroy frees it (:44).R8 by default or L8 via the _format variants. Stride is width plus configurable padding.