C# Class FarseerPhysics.Collision.AABB

An axis aligned bounding box.
Datei anzeigen Open project: prime31/Nez Class Usage Examples

Public Properties

Property Type Description
lowerBound Vector2
upperBound Vector2

Public Methods

Method Description
AABB ( Vector2 min, Vector2 max ) : System
AABB ( Vector2 center, float width, float height ) : System
combine ( AABB &aabb ) : void

Combine an AABB into this one.

combine ( AABB &aabb1, AABB &aabb2 ) : void

Combine two AABBs into this one.

contains ( AABB &aabb ) : bool

Does this aabb contain the provided AABB.

contains ( Vector2 &point ) : bool

Determines whether the AAABB contains the specified point.

isValid ( ) : bool

Verify that the bounds are sorted. And the bounds are valid numbers (not NaN).

rayCast ( RayCastOutput &output, RayCastInput &input, bool doInteriorCheck = true ) : bool

Raycast against this AABB using the specificed points and maxfraction (found in input)

testOverlap ( AABB &a, AABB &b ) : bool

Test if the two AABBs overlap.

Method Details

AABB() public method

public AABB ( Vector2 min, Vector2 max ) : System
min Vector2
max Vector2
return System

AABB() public method

public AABB ( Vector2 center, float width, float height ) : System
center Vector2
width float
height float
return System

combine() public method

Combine an AABB into this one.
public combine ( AABB &aabb ) : void
aabb AABB The aabb.
return void

combine() public method

Combine two AABBs into this one.
public combine ( AABB &aabb1, AABB &aabb2 ) : void
aabb1 AABB The aabb1.
aabb2 AABB The aabb2.
return void

contains() public method

Does this aabb contain the provided AABB.
public contains ( AABB &aabb ) : bool
aabb AABB The aabb.
return bool

contains() public method

Determines whether the AAABB contains the specified point.
public contains ( Vector2 &point ) : bool
point Vector2 The point.
return bool

isValid() public method

Verify that the bounds are sorted. And the bounds are valid numbers (not NaN).
public isValid ( ) : bool
return bool

rayCast() public method

Raycast against this AABB using the specificed points and maxfraction (found in input)
public rayCast ( RayCastOutput &output, RayCastInput &input, bool doInteriorCheck = true ) : bool
output RayCastOutput Output.
input RayCastInput Input.
doInteriorCheck bool If set to true do interior check.
return bool

testOverlap() public static method

Test if the two AABBs overlap.
public static testOverlap ( AABB &a, AABB &b ) : bool
a AABB The first AABB.
b AABB The second AABB.
return bool

Property Details

lowerBound public_oe property

The lower vertex
public Vector2 lowerBound
return Vector2

upperBound public_oe property

The upper vertex
public Vector2 upperBound
return Vector2