# Collide: Convex

[![crates.io](https://img.shields.io/crates/v/collide-convex)](https://crates.io/crates/collide-convex)
[![docs.rs](https://img.shields.io/docsrs/collide-convex)](https://docs.rs/collide-convex)

Convex hull collider for the [collide](https://crates.io/crates/collide) ecosystem. Dimension-generic (2D/3D/N-D).

Handles arbitrary convex shapes defined as the Minkowski sum of a convex hull (N points) and a sphere (radius). Uses GJK for distance computation and EPA for penetration depth.

## Usage

```rust
use collide::Collider;
use collide_convex::Convex;

let triangle = Convex::new(0.1, vec![p1, p2, p3].into());
let sphere = Convex::sphere(center, 1.0);
let capsule = Convex::capsule(0.5, start, end);

if triangle.check_collision(&sphere) {
    let info = triangle.collision_info(&sphere).unwrap();
}
```

## Features

- `ray` — enables `Collider<Ray>` for ray intersection via GJK raycast
