Adds a new Texture to the Texture Manager created from the given Base64 encoded data.
It works by creating an Image
DOM object, then setting the src
attribute to
the given base64 encoded data. As a result, the process is asynchronous by its nature,
so be sure to listen for the events this method dispatches before using the texture.
name | type | description |
---|---|---|
key | string |
The unique string-based key of the Texture. |
data | * |
The Base64 encoded data. |
This Texture Manager instance.