The Ellipse object is used to help draw graphics and can also be used to specify a hit area for displayObjects.

Memberof

PIXI

Constructors

Properties

Methods

Constructors

  • Parameters

    • Optional x: number

      The X coordinate of the center of this ellipse

    • Optional y: number

      The Y coordinate of the center of this ellipse

    • Optional halfWidth: number

      The half width of this ellipse

    • Optional halfHeight: number

      The half height of this ellipse

    Returns Ellipse

Properties

height: number

Default

0
type: ELIP

The type of the object, mainly used to avoid instanceof checks

Default

PIXI.SHAPES.ELIP

See

PIXI.SHAPES

width: number

Default

0
x: number

Default

0
y: number

Default

0

Methods

  • Creates a clone of this Ellipse instance

    Returns Ellipse

    A copy of the ellipse

  • Checks whether the x and y coordinates given are contained within this ellipse

    Parameters

    • x: number

      The X coordinate of the point to test

    • y: number

      The Y coordinate of the point to test

    Returns boolean

    Whether the x/y coords are within this ellipse

  • Returns the framing rectangle of the ellipse as a Rectangle object

    Returns Rectangle

    The framing rectangle

Generated using TypeDoc