Crate ncollide2d

source ·
Expand description

ncollide

ncollide is a 2 and 3-dimensional collision detection library written with the rust programming language.

As its name suggests, it is generic wrt the dimension: it works with both 2-dimensional and 3-dimensional shapes.

The official user guide is available here. The rustdoc documentation is available here.

Compilation

You will need the last stable build of the rust compiler and the official package manager: cargo.

Simply add the following to your Cargo.toml file:

[dependencies]
ncollide2d = "0.17" # For 2D collision detection.
ncollide3d = "0.17" # For 3D collision detection.

Features

  • dynamic bounding volume tree based broad phase
  • ball vs. ball collision detection,
  • plane vs. any convex object collision detection.
  • collision detection between arbitrary convex objects
  • compound shapes
  • ray-casting
  • time of impact computation for objects without rotational movement (compound vs. compound is not yet implemented)

And various traits for collision detectors and broad phase collision detection.

Modules

Bounding volumes.
Broad phases.
Structures for describing and storing collision-related events.
Compilation flags dependent aliases for mathematical types.
Persistent collision detection algorithms to compute contact points.
Spatial partitioning tools.
Procedural mesh generation.
Non-persistant pairwise geometric queries.
Collision shapes supported by ncollide.
Transformation, simplification and decomposition of meshes.
Various unsorted geometrical and logical operators.
High level API to detect collisions in large, complex scenes.