Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Implements

Index

Constructors

constructor

  • new R2Box(xMin: number, yMin: number, xMax: number, yMax: number): R2Box
  • Parameters

    • xMin: number
    • yMin: number
    • xMax: number
    • yMax: number

    Returns R2Box

Properties

Readonly xMax

xMax: number

Readonly xMin

xMin: number

Readonly yMax

yMax: number

Readonly yMin

yMin: number

Static hitX

hitX: number

Static hitY

hitY: number

Accessors

bottom

  • get bottom(): number
  • Returns number

bounds

  • Returns R2Box

center

  • Returns R2Point

height

  • get height(): number
  • Returns number

left

  • get left(): number
  • Returns number

right

  • get right(): number
  • Returns number

top

  • get top(): number
  • Returns number

width

  • get width(): number
  • Returns number

x

  • get x(): number
  • Returns number

y

  • get y(): number
  • Returns number

Methods

contains

  • contains(that: AnyR2Shape): boolean
  • contains(x: number, y: number): boolean
  • Parameters

    Returns boolean

  • Parameters

    • x: number
    • y: number

    Returns boolean

containsBox

  • containsBox(that: R2Box): boolean
  • Parameters

    Returns boolean

containsCircle

  • containsCircle(that: R2Circle): boolean
  • Parameters

    Returns boolean

containsPoint

  • containsPoint(that: R2Point): boolean
  • Parameters

    Returns boolean

containsSegment

  • Parameters

    Returns boolean

debug

  • debug(output: Output<unknown>): void
  • Parameters

    Returns void

equals

  • equals(that: unknown): boolean
  • Parameters

    • that: unknown

    Returns boolean

equivalentTo

  • equivalentTo(that: unknown, epsilon?: number): boolean
  • Parameters

    • that: unknown
    • Optional epsilon: number

    Returns boolean

hashCode

  • hashCode(): number
  • Returns number

interpolateTo

  • Parameters

    Returns Interpolator<R2Box>

  • Parameters

    • that: unknown

    Returns null | Interpolator<R2Box>

intersects

  • Parameters

    Returns boolean

intersectsBox

  • intersectsBox(that: R2Box): boolean
  • Parameters

    Returns boolean

intersectsCircle

  • intersectsCircle(that: R2Circle): boolean
  • Parameters

    Returns boolean

intersectsPoint

  • intersectsPoint(that: R2Point): boolean
  • Parameters

    Returns boolean

intersectsSegment

  • intersectsSegment(that: R2Segment): boolean
  • Parameters

    Returns boolean

isDefined

  • isDefined(): boolean
  • Returns boolean

toAny

  • Returns R2BoxInit

toString

  • toString(): string
  • Returns string

transform

union

  • Parameters

    Returns R2Box

Static fromAny

  • Parameters

    Returns R2Box

Static fromInit

  • Parameters

    Returns R2Box

Static intersectsSegment

  • intersectsSegment(d0: number, d1: number, x0: number, y0: number, x1: number, y1: number): boolean
  • Parameters

    • d0: number
    • d1: number
    • x0: number
    • y0: number
    • x1: number
    • y1: number

    Returns boolean

Static isAny

  • isAny(value: unknown): value is AnyR2Box
  • Parameters

    • value: unknown

    Returns value is AnyR2Box

Static isInit

  • Parameters

    • value: unknown

    Returns value is R2BoxInit

Static of

  • of(xMin: number, yMin: number, xMax?: number, yMax?: number): R2Box
  • Parameters

    • xMin: number
    • yMin: number
    • Optional xMax: number
    • Optional yMax: number

    Returns R2Box

Static undefined

  • Returns R2Box

Generated using TypeDoc