Global

Members

cachednumber

tint of the fill

cachednumber

tint of the line to draw

ifboolean

true the liens will be draw using LINES instead of TRIANGLE_STRIP

thenumber

color of the fill

thenumber

color of the line to draw

thenumber

width of the line to draw

Thenumber

type of the shape, see the Const.Shapes file for all the existing types,

shape object to draw.

thenumber

alpha of the fill

thenumber

alpha of the line to draw

whetherboolean

or not the shape is filled with a colour

Methods

areArraysEqual(array1, array2)boolean

Utility function to convert hexadecimal colors to strings, and simply return the color if it's a string. This version can also convert array of colors

Name Type Description
array1 Array

First array to compare

array2 Array

Second array to compare

Returns:
Type Description
boolean Do the arrays contain the same values in the same order

calculateScreenSpaceMatrix(filterArea, sprite, outputMatrix)

Calculates the mapped matrix

Name Type Description
filterArea Rectangle

The filter area

sprite Sprite

the target sprite

outputMatrix Matrix

@alvin

getColor(color)string

Utility function to convert hexadecimal colors to strings, and simply return the color if it's a string. This version can also convert array of colors

Name Type Description
color number | Array.<number>
Returns:
Type Description
string The color as a string.

getSingleColor(color)string

Utility function to convert hexadecimal colors to strings, and simply return the color if it's a string.

Name Type Description
color number | Array.<number>
Returns:
Type Description
string The color as a string.

premultiplyRgba(rgb, alpha, out, premultiply)Float32Array

combines rgb and alpha to out array

Name Type Default Description
rgb Float32Array | Array.<number>

input rgb

alpha number

alpha param

out Float32Array optional

output

premultiply boolean true optional

do premultiply it

Returns:
Type Description
Float32Array vec4 rgba

premultiplyTint(tint, alpha)number

premultiplies tint

Name Type Description
tint number

integet RGB

alpha number

floating point alpha (0.0-1.0)

Returns:
Type Description
number tint multiplied by alpha

premultiplyTintToRgba(tint, alpha, out, premultiply)Float32Array

converts integer tint and float alpha to vec4 form, premultiplies by default

Name Type Default Description
tint number

input tint

alpha number

alpha param

out Float32Array optional

output

premultiply boolean true optional

do premultiply it

Returns:
Type Description
Float32Array vec4 rgba

Type Definitions

DecomposedDataUriobject

Typedef for decomposeDataUri return object.

Properties:
Name Type Description
Media mediaType

type, eg. image

Sub subType

type, eg. png

Data encoding

encoding, eg. base64

The data

actual data

FrameObjectobject

Properties:
Name Type Description
texture PIXI.Texture

The PIXI.Texture of the frame

time number

the duration of the frame in ms

Sizeobject

Typedef for Size object.

Properties:
Name Type Description
Width width

component

Height height

component