Skip to content

Native Overlays (vros-overlay-builder)

vros-overlay-builder is the recommended way to build native vrOS overlays. It runs VR types on a dedicated VR thread and keeps async service work on the service thread (tokio runtime).

Minimal Runner

use vros_overlay_builder::OverlayRunner;
use my_overlay::MyOverlayApp;

#[tokio::main]
async fn main() -> anyhow::Result<()> {
    const CONFIG: &str = include_str!("../overlay.toml");
    OverlayRunner::from_toml(CONFIG)?
        .with_app(MyOverlayApp::new())
        .run()
        .await?;
    Ok(())
}

Standalone Testing

Overlays can opt into a standardized CLI for standalone/testing flows by calling run_with_cli() instead of run(). This supports --standalone and can export pipe names like VROS_CONTROL_PIPE/VROS_EVENT_PIPE.

Reference Overlay

For a “real” shipped overlay example, see crates/vros-chat/.