Constructors
constructor
- new Box2(min?, max?): Box2
Properties
min
max
Methods
set
- set(min, max): Box2
setFromPoints
- setFromPoints(points): Box2
setFromCenterAndSize
- setFromCenterAndSize(center, size): Box2
clone
- clone(): this
Returns this
copy
- copy(box): this
Returns this
makeEmpty
- makeEmpty(): Box2
isEmpty
- isEmpty(): boolean
Returns boolean
getCenter
- getCenter(target): Vector2
getSize
- getSize(target): Vector2
expandByPoint
- expandByPoint(point): Box2
expandByVector
- expandByVector(vector): Box2
expandByScalar
- expandByScalar(scalar): Box2
containsPoint
- containsPoint(point): boolean
Returns boolean
containsBox
- containsBox(box): boolean
Returns boolean
getParameter
- getParameter(point, target): Vector2
intersectsBox
- intersectsBox(box): boolean
Returns boolean
clampPoint
- clampPoint(point, target): Vector2
distanceToPoint
- distanceToPoint(point): number
Returns number
intersect
- intersect(box): Box2
union
- union(box): Box2
translate
- translate(offset): Box2
equals
- equals(box): boolean
Returns boolean
empty
- empty(): any
Returns any
isIntersectionBox
- isIntersectionBox(b): any
Returns any
Default