Copyright (C) 2001-2007 Russell L. Smith.
Copyright (C) 2008-2026 Open Dynamics Engine contributors.
ODE is a free, industrial quality library for simulating articulated rigid body dynamics - for example ground vehicles, legged creatures, and moving objects in VR environments. It is fast, flexible, robust and platform independent, with advanced joints, contact with friction, and built-in collision detection.
SPDX-License-Identifier: BSD-3-Clause OR LGPL-2.1-or-later
ODE is dual-licensed under either:
Third-party libraries bundled with ODE:
- GIMPACT — dual-licensed under either:
- libccd — Modified 3-clause BSD License.
- OU/ODER — triple-licensed under either:
- OPCODE — under the same terms as ODE. See OPCODE/COPYING.
- The ODE web pages are at ode.org.
- An online manual is at the Wiki.
- API documentation is in the file ode/docs/index.html, or you can view it on the web at opende.sf.net/docs/index.html.
- Coding style requirements can be found in the CSR.txt file.
ODE uses CMake as its build system. CMake can generate project files for many platforms and IDEs including Unix Makefiles, Ninja, Visual Studio, Xcode, and more.
- CMake 3.10 or later
- A C/C++ compiler (GCC, Clang, MSVC, MinGW, etc.)
- OpenGL and GLU (only if building demos with
-DODE_WITH_DEMOS=ON)
cmake -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel
cmake --install buildTo run the test suite:
ctest --test-dir build --output-on-failureA specific generator can be selected with -G:
cmake -B build -G "Ninja" -DCMAKE_BUILD_TYPE=Release
cmake -B build -G "Visual Studio 17 2022"
cmake -B build -G "MSYS Makefiles" -DCMAKE_BUILD_TYPE=Release
cmake -B build -G "Xcode"Most modern IDEs (Visual Studio, CLion, Qt Creator, VS Code) can open the
source directory with the CMakeLists.txt file directly.
Options can be set with -D on the cmake command line:
cmake -B build -DODE_DOUBLE_PRECISION=ON -DODE_WITH_DEMOS=OFF| Option | Description | Default |
|---|---|---|
ODE_DOUBLE_PRECISION |
Use double-precision math | ON (64-bit), OFF (32-bit) |
ODE_WITH_DEMOS |
Build demo applications and DrawStuff library (requires OpenGL) | ON |
ODE_WITH_TESTS |
Build the unit test application | ON |
ODE_WITH_OPCODE |
Use OPCODE for trimesh collisions | ON |
ODE_WITH_GIMPACT |
Use GIMPACT for trimesh collisions (experimental) | OFF |
ODE_WITH_LIBCCD |
Use libccd for additional collision tests | OFF |
ODE_WITH_OU |
Use TLS for global caches, allows threaded collision checks | OFF |
ODE_16BIT_INDICES |
Use 16-bit trimesh indices instead of 32-bit | OFF |
ODE_NO_THREADING_INTF |
Disable threading interface support | OFF |
BUILD_SHARED_LIBS |
Build shared library instead of static | ON |
When ODE_WITH_LIBCCD is ON, additional sub-options become available for
specific collision pairs (box-cylinder, capsule-cylinder, convex-convex, etc.).
See CMakeLists.txt for the full list.
cmake -B build
cmake --build build --config Release --parallelCMake will auto-detect Visual Studio. The library output name includes the
precision by default (ode_double or ode_single).
From an MSYS2 shell (mingw64, ucrt64, or clang64):
cmake -G "MSYS Makefiles" -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel $(nproc)cmake -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel $(nproc)
sudo cmake --install buildDemos require OpenGL development packages. On Debian/Ubuntu:
sudo apt-get install libglu1-mesa-dev freeglut3-devcmake -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel $(sysctl -n hw.ncpu)Xcode projects can be generated with -G Xcode.