Agent skill · software engineering · aradotso
webphysics-avbd-engine
WebGPU rigid-body/soft-body physics engine based on the AVBD (Augmented Vertex Block Descent) solver
Why this skill is useful
Adds a complete WebGPU physics engine with executable code for rigid-body and soft-body simulations that the AI cannot generate on its own.
What it needs
Requires git, npm installed locally. About 5k tokens when loaded. Last updated 2026-07-09. 70 stars on the source repository.
What this skill does
webphysics-avbd-engine Skill by ara.so — Daily 2026 Skills collection. What It Does webphysics is an experimental WebGPU-accelerated rigid-body and soft-body physics engine implementing the AVBD (Augmented Vertex Block Descent) solver from Giles et al. (2025). It runs entirely on the GPU using WebGPU compute shaders and supports: Rigid-body simulation with contacts, friction, and joints GPU broad-phase collision detection via LBVH (Linear BVH) Narrow-phase manifold generation with warm-start persistence Graph-coloring-based parallel body solves Springs and soft-body constraints Body sleeping/diagnostics Browser support: Chrome only (requires WebGPU). This is an experimental proof-of-concept, not a production library. Installation & Setup The dev server typically starts at http://localhost:5173 (Vite-based). Project Structure Core API Usage Initializing the Physics Engine Adding Rigid Bodies Stepping the Simulation Reading Body State for Rendering Adding Joints / Constraints Adding Springs (Soft Bodies) AVBD Pipeline Reference The solver follows Algorithm 1 from the AVBD paper: Key files per stage: Stage File ------- ------ Orchestration src/physics/PhysicsEngine.ts Broad phase src/physics/gpu/broadPhase.ts Narrow phase src/physics/gpu/contactGeneration.ts Contact records src/physics/gpu/contactRecord.ts AVBD solve src/physics/gpu/avbdState.ts LBVH builder src/lvbh/GPULBVHBuilder.ts Configuration Patterns Solver Parameters Tuning Stability Increase substeps (e.g., 20) for stiff stacks or fast-moving bodies Increase iterations for better constraint convergence Use mass: 0 for static bodies (never moves, acts as infinite mass) Lower stiffness values for softer, more stable joints Set restitution: 0 + high friction for non-bouncy stacking Common Patterns Stack of Boxes Pendulum Chain with Distance Joints Integrate with Three.js Rendering Troubleshooting WebGPU Not Available Only Chrome 113+ supports WebGPU by default Enable via chrome://flags/#enable-unsafe-webgpu on ol …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills aradotso/webphysics-avbd-engine