Skip to content

tatsuya-ogawa/MetalAVBD

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MetalAVBD: Augmented Vertex Block Descent in Metal

demo

Metal Swift SIGGRAPH 2025 Platform

MetalAVBD is a GPU-accelerated implementation of the Augmented Vertex Block Descent (AVBD) solver in Metal 4.

This project is a Metal-based realization of the research project from the University of Utah:

Augmented Vertex Block Descent
Chris Giles, Elie Diaz, and Cem Yuksel
ACM Transactions on Graphics (Proceedings of SIGGRAPH 2025)


📽 Demos & Research


🚀 Key Solver Features

Following the principles of the AVBD research, this implementation offers:

  • Unconditional Stability: Converges toward the implicit Euler solution, ensuring physical correctness even with large timesteps.
  • Augmented Lagrangian Formulation: Handles hard constraints with infinite stiffness without numerical instabilities or the "softness" common in traditional penalty methods.
  • Convergence: Improved convergence rates in scenes with high stiffness ratios.
  • GPU Pipeline:
    • Full GPU broadphase using spatial hashing.
    • Parallel Gauss-Seidel solver utilizing contact-aware body coloring for deterministic stability.
  • Scale: Capable of simulating millions of interacting objects in real-time.

🛠 Metal 4 Technical Implementation

This project is optimized for modern Apple Silicon and Metal 4 features:

  • GPU Task Scheduling: Leverages adjacency-based coloring to orchestrate constraint solving with minimal contention.
  • Descriptor Management: Uses Argument Tables and Residency Sets for efficient resource access.
  • Atomic Memory Management: Optimized compute shaders using atomic batching to manage dynamic contact manifolds and allocations on the GPU.
  • Diverse Primitive Manifolds:
    • Box (SAT): Accurate face/edge/vertex collision.
    • Sphere: Analytical geometry checks.
    • Torus: Advanced collision manifold generation via approximate sphere decomposition.
    • SDF (Signed Distance Field): High-performance collision against complex mesh geometry using pre-generated 3D volumes.
  • SDF Visualization: Real-time raymarching visualizer for debugging and inspecting SDF volume alignment and quality.

🚧 Limitations

  • SDF-to-SDF Collision: Currently, collision detection between two SDF-based objects is not implemented. Only Primitive-to-SDF collisions are supported.

📱 Requirements

  • Device: Physical iOS device (A17 Pro / M1 or later) or Apple Silicon Mac.
  • OS: iOS 18.0+ / macOS 15.0+ (Metal 4 support required).
  • Tooling: Xcode 16.0+

Important

This project utilizes advanced Metal features and cannot be run on the iOS Simulator. Please use a physical device or the "macOS Designed for iPad" destination.

📜 License & Acknowledgments

This implementation is independent of the original authors' code but is built strictly according to the mathematical foundations laid out in their research.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages