Regexp for data URI. Based on: https://github.com/ragingwind/data-uri-regex
maps premultiply flag and blendMode to adjusted blendMode
Removes all textures from cache, but does not destroy them
changes blendMode according to texture format
supposed blend mode
whether source is premultiplied
true blend mode for this texture
Generic Mask Stack data structure
Number of quads
Split a data URI into components. Returns undefined if
parameter dataUri
is not a valid data URI.
the data URI to check
The decomposed data uri or undefined
Helper for warning developers about deprecated features & settings. A stack track for warnings is given; useful for tracking-down where deprecated methods/properties/classes are being used within the code.
The version where the feature became deprecated
Message should include what is deprecated, where, and the new solution
Destroys all texture in the cache
get the resolution / device pixel ratio of an asset by looking for the prefix used by spritesheets and image urls
the image path
resolution / device pixel ratio of an asset
Converts a hexadecimal color number to an [R, G, B] array of normalized floats (numbers from 0.0 to 1.0).
The hexadecimal number to convert
An array representing the [R, G, B] of the color where all values are floats.
Converts a hexadecimal color number to a string.
Number in hex (e.g., 0xffffff
)
The string color (e.g., "#ffffff"
).
Checks if a number is a power of two.
input value
true
if value is power of two
Helper for checking for WebGL support.
Is WebGL supported.
Computes ceil of log base 2
input value
logarithm base 2
Rounds to next power of two.
input value
combines rgb and alpha to out array
input rgb
alpha param
vec4 rgba
premultiplies tint
integer RGB
floating point alpha (0.0-1.0)
tint multiplied by alpha
converts integer tint and float alpha to vec4 form, premultiplies by default
input tint
alpha param
vec4 rgba
Remove items from a javascript array without generating garbage
Array to remove elements from
starting index
how many to remove
Converts a color as an [R, G, B] array of normalized floats to a hexadecimal number.
Array of numbers where all values are normalized floats from 0.0 to 1.0.
Number in hexadecimal.
Logs out the version and renderer information for this running instance of PIXI.
If you don't want to see this message you can run PIXI.utils.skipHello()
before
creating your renderer. Keep in mind that doing that will forever make you a jerk face.
The string renderer type to log.
Returns sign of number
the number to check the sign of
0 if n
is 0, -1 if n
is negative, 1 if n
is positive
Skips the hello message of renderers that are created after this is run.
Converts a string to a hexadecimal color number. It can handle: hex strings starting with #: "#ffffff" hex strings starting with 0x: "0xffffff" hex strings without prefix: "ffffff" css colors: "black"
The string color (e.g., "#ffffff"
)
Number in hexadecimal.
Trim transparent borders from a canvas
the canvas to trim
Trim data
Gets the next unique identifier
The next unique identifier to use.
Generated using TypeDoc
Describe property usage
BaseTextureCache
PIXI.utils