Dependencies¶
Default dependencies of the ipc::toolkit library. Edge colour is the link scope; a dashed edge marks an optional dependency, enabled by default but controlled by an IPC_TOOLKIT_WITH_* CMake option. Dependencies that are off by default are omitted. Excludes CUDA and Python bindings.¶
The IPC Toolkit depends on a handful of third-party libraries, which are used to provide various functionality.
All required dependencies are downloaded through CMake depending on the build options, and are built automatically when you build the IPC Toolkit. You do not need to install them separately.
These dependencies are all permissively licensed, and we list them here to give due credit!
Name |
Purpose |
License |
Link |
|---|---|---|---|
Eigen |
Linear algebra |
MPL-2.0 |
|
libigl |
Geometry functions and predicates |
MPL-2.0 |
|
oneTBB |
Multithreading |
Apache-2.0 |
|
Tight-Inclusion |
Provably conservative CCD |
MIT |
|
Scalable-CCD |
Scalable (GPU) CCD |
Apache-2.0 |
|
spdlog |
Logger |
MIT |
|
TinyAD |
Automatic differentiation for testing and in non-performance critical smooth contact functions |
MIT |
Optional Dependencies¶
Additionally, IPC Toolkit may optionally use the following libraries:
Name |
Purpose |
License |
Link |
Enabled |
CMake Option |
|---|---|---|---|---|---|
xsimd |
Cross-platform SIMD library for vectorization |
BSD-3-Clause |
✅ |
|
|
robin-map |
Faster hashing |
MIT |
✅ |
|
|
Abseil |
Hashing utilities |
Apache-2.0 |
✅ |
|
|
filib |
Interval arithmetic for nonlinear trajectories/CCD |
LGPL-2.1 |
✅ |
|
|
MeshFEMSparse |
Block-CSC data structures for fast Hessian assembly (see |
MIT |
✅ |
|
|
nlohmann/json |
JSON parsing for profiler and tests |
MIT |
⬜ |
|
|
Tracy |
Frame profiler |
BSD-3-Clause |
⬜ |
|
|
rational-cpp |
Rational arithmetic used for exact intersection checks (requires GMP to be installed at a system level) |
MIT |
⬜ |
|
|
Etienne Vouga’s Collision Detection Library |
Inexact CCD (included for comparison with the original IPC library) |
??? |
⬜ |
|
Some of these libraries are enabled by default, and some are not. You can enable or disable them by passing the appropriate CMake option when you configure the IPC Toolkit build.
Warning
xsimd is linked publicly, and the detected SIMD flags (SIMD_CXX_FLAGS, typically -march=native) are applied publicly to anything linking ipc::toolkit. This is a requirement rather than a convenience: ipc/utils/simd.hpp exposes ipc::SimdBatch<T> in the public API, and xsimd::default_arch is resolved from each translation unit’s own compiler flags. A consumer compiled without these flags therefore names a different batch type than the one instantiated inside the library, and the link fails.
The practical consequence is that your binaries are compiled for the machine that built them and will not run on hardware lacking those instructions. If you need portable binaries, set IPC_TOOLKIT_WITH_SIMD to OFF; the library then builds without xsimd and without the architecture flags.
Note
MeshFEMSparse (and its transitive dependency MeshFEMCore) is downloaded source-only and compiled into a minimal static library (matrix data structures and assembly routines; no sparse direct solvers). When enabled (the default), ipc::Potential::hessian() assembles through the block-CSC backend — several times faster than the triplet-based assembly, with identical results up to floating-point summation order — and a ipc::MeshFEMHessianAssembler held across ipc::Potential::assemble_hessian() calls additionally reuses the sparsity pattern between assemblies. It requires IPC_TOOLKIT_VERTEX_DERIVATIVE_LAYOUT=RowMajor (the default; the option is automatically disabled otherwise).
Warning
filib is licensed under LGPL-2.1 and as such it is required to be dynamically linked. Doing so automatically is a challenge, so by default we use static linkage. Enabling dynamic linkage requires copying the .so/.dylib/.dll file to the binary directory or system path. To enable this, set the CMake option FILIB_BUILD_SHARED_LIBS to ON and add this CMake code to copy the shared library object to the binary directory:
# Copy shared lib to the output directory
add_custom_command(
TARGET ${MY_EXE_TARGET} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_RUNTIME_DLLS:${MY_EXE_TARGET}> $<TARGET_FILE_DIR:${MY_EXE_TARGET}>
COMMAND_EXPAND_LISTS
)
where ${MY_EXE_TARGET} is the name of your executable target. If you know a better way to handle this, please let us know!
If you would rather avoid LGPL code entirely, you can disable filib by setting IPC_TOOLKIT_WITH_FILIB to OFF. With this option disabled, CMake will not download or use any of filib’s code.
Python Bindings Dependencies¶
The following dependencies are optionally used when building Python bindings:
Name |
Purpose |
License |
Link |
Enabled |
CMake Option |
|---|---|---|---|---|---|
Pybind11 |
Python bindings |
BSD-3-Clause |
✅ |
|
|
pybind11_json |
JSON support for pybind11 (used in profiler) |
MIT |
⬜ |
|
Unit Test Dependencies¶
The following dependencies are optionally used when unit tests are enabled:
Name |
Purpose |
License |
Link |
Enabled |
CMake Option |
|---|---|---|---|---|---|
Catch2 |
Testing framework |
BSL-1.0 |
✅ |
|
|
finite-diff |
Finite-difference comparisons |
MIT |
✅ |
|