BBox
class BBox implements TypeWebGLConvertible
Constructors
constructor
public new BBox(): BBox
Properties
height
public height: number = 0
width
public width: number = 0
x
public x: number = 0
y
public y: number = 0
symbol
static readonly public symbol: typeof symbol = ...
Accessors
bottom
public set bottomvalue: number: void
public get bottom(): number
Parameters
value: number
bottomLeft
public get bottomLeft(): Vector2
bottomRight
public get bottomRight(): Vector2
center
public get center(): Vector2
corners
public get corners(): Vector2Vector2Vector2Vector2
left
public set leftvalue: number: void
public get left(): number
Parameters
value: number
pixelPerfect
public get pixelPerfect(): BBox
position
public set positionvalue: Vector2: void
public get position(): Vector2
Parameters
value: Vector2
right
public set rightvalue: number: void
public get right(): number
Parameters
value: number
size
public get size(): Vector2
top
public set topvalue: number: void
public get top(): number
Parameters
value: number
topLeft
public get topLeft(): Vector2
topRight
public get topRight(): Vector2
Methods
addSpacing
public addSpacingvalue: PossibleSpacing: BBox
Expand the bounding box to accommodate the given spacing.
Deprecated
Use expand instead.
Parameters
value: PossibleSpacingThe value to expand the bounding box by.
expand
public expandvalue: PossibleSpacing: BBox
Expand the bounding box to accommodate the given spacing.
Parameters
value: PossibleSpacingThe value to expand the bounding box by.
includes
public includespoint: Vector2: boolean
Parameters
point: Vector2
intersection
public intersectionother: BBox: BBox
Parameters
other: BBox
intersects
public intersectsother: BBox: boolean
Parameters
other: BBox
lerp
Parameters
serialize
public serialize(): SerializedBBox
toString
public toString(): string
Returns a string representation of an object.
toSymbol
public toSymbol(): symbol
toUniform
Parameters
transform
public transformmatrix: PossibleMatrix2D: BBox
Parameters
matrix: PossibleMatrix2D
transformCorners
public transformCornersmatrix: PossibleMatrix2D: Vector2[]
Parameters
matrix: PossibleMatrix2D
translate
public translatevector: PossibleVector2: BBox
Translate the bounding box by the given vector.
Parameters
vector: PossibleVector2The vector to translate the bounding box by.
union
public unionother: BBox: BBox
Parameters
other: BBox
arcLerp
Parameters
createSignal
static public createSignalinitial?: SignalValuePossibleBBoxinterpolation: InterpolationFunctionBBox = BBox.lerp: RectSignalvoid
Parameters
initial?: SignalValuePossibleBBoxinterpolation: InterpolationFunctionBBox = BBox.lerp
fromBBoxes
static public fromBBoxes...boxes: BBox[]: BBox
Parameters
...boxes: BBox[]
fromPoints
static public fromPoints...points: Vector2[]: BBox
Parameters
...points: Vector2[]
fromSizeCentered
static public fromSizeCenteredsize: Vector2: BBox
Parameters
size: Vector2