These bindings are still feature-incomplete and unstable.
Features:
- Geometry types
- Primitives
- Meshes
- Rigid bodies
- Joints
- Vehicles
- Characters
Platforms:
- Linux (x86_64)
- Windows (x86_64)
- MacOS (x86_64, arm64)
Build types (change with Gradle flag -PbuildType= or property buildType):
debugreleasedistribution(default)
Flavors (change with Gradle flag -Pflavor= or property flavor):
sp(single-precision floating point, default)dp(double-precision floating point)
repositories {
mavenCentral()
}
dependencies {
implementation("io.github.aecsocket", "jolt-jni", "VERSION")
runtimeOnly("io.github.aecsocket", "jolt-jni-natives-linux", "VERSION")
runtimeOnly("io.github.aecsocket", "jolt-jni-natives-windows", "VERSION")
runtimeOnly("io.github.aecsocket", "jolt-jni-natives-macos", "VERSION")
runtimeOnly("io.github.aecsocket", "jolt-jni-natives-macos-arm64", "VERSION")
}Usage is very similar to JoltPhysics. See HelloJolt.java to get a minimal implementation.
// Load the native libraries from the jar (in `jolt/`)
JoltEnvironment.load();
// Or load them manually
// System.load("name-of-lib-file");
// Do some Jolt setup
JoltEnvironment.registerDefaultAllocator();
RTTIFactory.setInstance(new RTTIFactory());
JoltEnvironment.registerTypes();You need Ninja installed.
git clone https://github.com/aecsocket/jolt-jni
cd jolt-jni
git submodule update --init
./gradlew build