Rapier C — 2D / f32 0.36.0+c.0
Loading...
Searching...
No Matches
R2ShapeCastHit Struct Reference

Shape-cast impact geometry; collider-side data is world-space, moving-shape data is local. More...

#include <rapier.h>

Data Fields

struct R2ColliderHandle collider
 World-bound collider handle.
R2Real time_of_impact
 Ray/sweep parameter at first impact, bounded by the query options.
struct R2Vector witness1
 Impact witness on the collider, in world coordinates.
struct R2Vector witness2
 Impact witness on the moving shape, in its local coordinates.
struct R2Vector normal1
 Impact normal on the collider, in world coordinates.
struct R2Vector normal2
 Impact normal on the moving shape, in its local coordinates.
uint32_t status
 Native result: 0 out of iterations, 1 converged, 2 failed, 3 penetrating or within target distance.

Detailed Description

Shape-cast impact geometry; collider-side data is world-space, moving-shape data is local.

Field Documentation

◆ collider

struct R2ColliderHandle R2ShapeCastHit::collider

World-bound collider handle.

◆ normal1

struct R2Vector R2ShapeCastHit::normal1

Impact normal on the collider, in world coordinates.

◆ normal2

struct R2Vector R2ShapeCastHit::normal2

Impact normal on the moving shape, in its local coordinates.

◆ status

uint32_t R2ShapeCastHit::status

Native result: 0 out of iterations, 1 converged, 2 failed, 3 penetrating or within target distance.

◆ time_of_impact

R2Real R2ShapeCastHit::time_of_impact

Ray/sweep parameter at first impact, bounded by the query options.

◆ witness1

struct R2Vector R2ShapeCastHit::witness1

Impact witness on the collider, in world coordinates.

◆ witness2

struct R2Vector R2ShapeCastHit::witness2

Impact witness on the moving shape, in its local coordinates.


The documentation for this struct was generated from the following file: