webxr-passthrough
Installation
SKILL.md
WebXR Passthrough & Mixed Reality
Quick Start
import * as THREE from 'three';
import { ARButton, RealityAccelerator } from 'ratk';
// 1. Alpha-transparent renderer (required for passthrough)
const renderer = new THREE.WebGLRenderer({ alpha: true, antialias: true });
renderer.xr.enabled = true;
renderer.setClearColor(0x000000, 0);
scene.background = null;
// 2. AR button with MR features
ARButton.convertToARButton(document.getElementById('ar-btn'), renderer, {
requiredFeatures: ['local-floor', 'hit-test', 'plane-detection'],
optionalFeatures: ['anchors', 'mesh-detection', 'layers'],
});