NOTE: This project is highly expremental.
ACG is a toolbox designed for study use mainly about Physical Simulation, but not Rendering.
Although we have seen a huge number of libraries designed for CG, (and in many areas):
- libigl: designed for geometry processing, the header-only coding style just leads to long compile time. The types of objects that igl-viewer can render is limitted.
- Taichi: GPU-based Parallel computing library, designed for Physical Simulation. Taichi is originally a community-driven project, and lacks Debugger support, and exception support.
On my macbook with Apple's Silicon, Taichi's crash will leads to OS's crash.
-
Core:
-
General Utilities:
log
: based on SPDLOGgod
: a meta programming library for Compile Time Computingjson
: import nlohmann json.- lots of tiny staff: such as
Result<T>
, unified & cross-platform time module, etc.
-
Init: Hookers for global variables designed for shared/static libraries.
-
Mathematics Tools: Import
Eigen
, and defines some types, such asField
,TriangleList
. -
Parallel computing tools: Import
Taskflow
-
SAD(Static Auto Diff): a high performance and highly optimized compile-time AutoDiff Library.
-
…
-
-
Gui:
- (Finished) Scene visualization: Support Mesh(including instancing), Particles, and Wireframe.
- (Finished) ImGUI & Vulkan based. high performance
- (Finished) ImGUI based User Interface, and User Callback.
- (Finished) Perspective/Ortho projection modes. (for 2D data-visualization, similar to Unity2d's design.)
- Scene Editing/Storaging/...
-
Port: Data import module.
-
Plugins (not implemented)
- libigl/cgal/... integration.
-
Examples, see below.
This repo is designed for study use. Some implemented (just demos, not optimized, debugged) algorithms are listed below:
mass-spring system based on Projective Dynamics. Refer to "Fast mass spring" by Tiantian Liu.
and this provides an bonus solver, which applies a single step of Jacobi method on PD, which leads to real-time simulation of traditional mass-spring at about 30fps (on my laptop).
Now, mass spring will also show the dynamic computed grid (SubdivisonAABB) for further Broad Phase CCD app.
Quasi Newton solver, the algorithm is same as example "hybred" below.
Quasi newton based solver for both cloth
and softbody
solve. (Implicit Euler)
- Left: Mass Spring
- Right: Ogden Neo-Hookean
![with tracing](./media/with tracing.png)
fem-implicit
: first-order explicit integrator. NeoHookean or StVK FEM Soft Body Simulation.mpm-explicit
: APIC-Fluid simulation, toy P2G and G2P process, weakly-compressible.