MAabb2 class
- Implemented types
Constructors
- MAabb2(Vector2 min, Vector2 max)
-
Create a new AABB with a
minandmax. Copies both corners. - MAabb2.centerAndHalfExtents(Vector2 center, Vector2 halfExtents)
-
Create a new AABB with a
centerandhalfExtents.factory - MAabb2.copy(Aabb2 other)
-
Create a new AABB as a copy of
other.factory - MAabb2.zero()
- Create a new AABB with min and max set to the origin.
Properties
- center → Vector2
-
The center of the AABB. Allocates a new Vector2.
no setterinherited
- centerX → double
-
The x coordinate of the center of the AABB.
no setterinherited
- centerY → double
-
The y coordinate of the center of the AABB.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- height → double
-
The height of the AABB.
no setterinherited
- max → MVector2
-
The maximum point defining the AABB.
final
- min → MVector2
-
The minimum point defining the AABB.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- width → double
-
The width of the AABB.
no setterinherited
Methods
-
clone(
) → MAabb2 -
Clone of this.
override
-
containsAabb2(
Aabb2 other) → bool -
Return if this contains
other.inherited -
containsVector2(
Vector2 point) → bool -
Return if this contains
point.inherited -
hull(
Aabb2 other) → void -
Set the min and max of this so that this is a hull of this and
other. -
hullPoint(
Vector2 point) → void -
Set the min and max of this so that this contains
point. -
intersectsWithAabb2(
Aabb2 other) → bool -
Return if this intersects with
other.inherited -
intersectsWithVector2(
Vector2 point) → bool -
Return if this intersects with
point.inherited -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
overlapsX(
Aabb2 other) → bool -
Return if this and
otheroverlap on the x axis.inherited -
overlapsY(
Aabb2 other) → bool -
Return if this and
otheroverlap on the y axis.inherited -
setCenterAndHalfExtents(
Vector2 center, Vector2 halfExtents) → void -
Set the AABB by a
centerandhalfExtents. -
setFrom(
Aabb2 other) → void -
Copy the min and max from
otherinto this. -
setValues(
double minX, double minY, double maxX, double maxY) → void - Set both corners from raw components.
-
toString(
) → String -
Returns a printable string.
inherited
Operators
-
operator ==(
Object other) → bool -
Check if two AABBs are the same.
inherited