Box2D.Dynamics.b2RayCastCallback
Class b2RayCastCallback
Namespace: Box2D.Dynamics
Assembly: Box2D.dll, box2d.iOS.dll
public abstract class b2RayCastCallback
Inheritance
Inherited Members
object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Constructors
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
b2RayCastCallback()
protected b2RayCastCallback()
Methods
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
Called for each fixture found in the query. You control how the ray cast proceeds by returning a float: return -1: ignore this fixture and continue return 0: terminate the ray cast return fraction: clip the ray to this point return 1: don't clip the ray and continue
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
the fixture hit by the ray
point
b2Vec2
the point of initial intersection
normal
b2Vec2
the normal vector at the point of intersection
fraction
float
Returns
-1 to filter, 0 to terminate, fraction to clip the ray for closest hit, 1 to continue
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
Called for each fixture found in the query. You control how the ray cast proceeds by returning a float: return -1: ignore this fixture and continue return 0: terminate the ray cast return fraction: clip the ray to this point return 1: don't clip the ray and continue
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
the fixture hit by the ray
point
b2Vec2
the point of initial intersection
normal
b2Vec2
the normal vector at the point of intersection
fraction
float
Returns
-1 to filter, 0 to terminate, fraction to clip the ray for closest hit, 1 to continue
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float
Returns
ReportFixture(b2Fixture, b2Vec2, b2Vec2, float)
public abstract float ReportFixture(b2Fixture fixture, b2Vec2 point, b2Vec2 normal, float fraction)
Parameters
fixture
b2Fixture
point
b2Vec2
normal
b2Vec2
fraction
float