Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Rect

Hierarchy

  • Rect

Index

Constructors

constructor

  • new Rect(xMin?: number, yMin?: number, width?: number, height?: number): Rect
  • Parameters

    • Optional xMin: number
    • Optional yMin: number
    • Optional width: number
    • Optional height: number

    Returns Rect

Accessors

height

  • get height(): number
  • set height(val: number): void
  • Returns number

  • Parameters

    • val: number

    Returns void

width

  • get width(): number
  • set width(val: number): void
  • Returns number

  • Parameters

    • val: number

    Returns void

xMax

  • get xMax(): number
  • Returns number

xMin

  • get xMin(): number
  • set xMin(val: number): void
  • Returns number

  • Parameters

    • val: number

    Returns void

yMax

  • get yMax(): number
  • Returns number

yMin

  • get yMin(): number
  • set yMin(val: number): void
  • Returns number

  • Parameters

    • val: number

    Returns void

Methods

clone

  • 拷贝该向量

    memberof

    Rect

    Returns Rect

    拷贝出来的对象

getCenter

  • Returns Vector2

set

  • set(rect: Rect): void
  • Parameters

    Returns void

transformByPositionScale

  • Parameters

    Returns void

Static createFromArray

  • createFromArray(array: number[]): Rect
  • 使用一个数组创建
    此操作会拷贝一份数组

    static
    memberof

    Rect

    Parameters

    • array: number[]

    Returns Rect

Generated using TypeDoc