Class: Ellipse

PIXI. Ellipse

new Ellipse(x, y, width, height)

The Ellipse object can be used to specify a hit area for displayObjects

Parameters:
Name Type Description
x Number

The X coordinate of the center of the ellipse

y Number

The Y coordinate of the center of the ellipse

width Number

The half width of this ellipse

height Number

The half height of this ellipse

Source - pixi/geom/Ellipse.js, line 5

Members

height :Number

Default Value:
  • 0
Source - pixi/geom/Ellipse.js, line 38

width :Number

Default Value:
  • 0
Source - pixi/geom/Ellipse.js, line 31

x :Number

Default Value:
  • 0
Source - pixi/geom/Ellipse.js, line 17

y :Number

Default Value:
  • 0
Source - pixi/geom/Ellipse.js, line 24

Methods

clone() → {PIXI.Ellipse}

Creates a clone of this Ellipse instance

Returns:

a copy of the ellipse

Source - pixi/geom/Ellipse.js, line 46

contains(x, y) → {Boolean}

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

Parameters:
Name Type Description
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

Source - pixi/geom/Ellipse.js, line 57

getBounds() → {PIXI.Rectangle}

Returns the framing rectangle of the ellipse as a PIXI.Rectangle object

Returns:

the framing rectangle

Source - pixi/geom/Ellipse.js, line 80
Phaser Copyright © 2012-2014 Photon Storm Ltd.
Documentation generated by JSDoc 3.3.0-dev on Sat Nov 15 2014 19:55:14 GMT-0000 (GMT) using the DocStrap template.