[src]

Struct ncollide2df64::narrow::BallBall

pub struct BallBall {
    // some fields omitted
}

Collision detector between two balls.

Methods

impl BallBall

fn new(prediction: N) -> BallBall

Creates a new persistent collision detector between two balls.

Trait Implementations

impl<__E: Encoder> Encodable<__E> for BallBall

Automatically derived.

fn encode(&self, __arg_0: &mut __E)

impl<__D: Decoder> Decodable<__D> for BallBall

Automatically derived.

fn decode(__arg_0: &mut __D) -> BallBall

impl Clone for BallBall

fn clone(&self) -> BallBall

impl CollisionDetector<Ball, Ball> for BallBall

fn update(&mut self, ma: &M, a: &Ball, mb: &M, b: &Ball)

Runs the collision detection on two objects. It is assumed that the same collision detector (the same structure) is always used with the same pair of object.

fn num_colls(&self) -> uint

The number of collision detected during the last update.

fn colls(&self, out_colls: &mut ~[Contact])

Collects the collisions detected during the last update.

fn toi(_: Option<BallBall>, c1: &M, dir: &V, _: &N, b1: &Ball, c2: &M, b2: &Ball) -> Option<N>

Computes the time of impact of two objects.

Arguments

  • m1 - the first object transform.
  • dir - the first object displacement direction.
  • dist - the first object displacement distance.
  • g1 - the first object.
  • m2 - the second object transform.
  • g2 - the second object.