A reference to the current renderer
Manually add an item to the uploading queue.
Object to add to the queue
Instance of plugin for chaining.
Destroys the plugin, don't use after this.
Actually prepare items. This is handled outside of the tick because it will take a while and we do NOT want to block the current animation frame from rendering.
Adds hooks for finding items.
Function call that takes two parameters: item:*, queue:Array
function must return true
if it was able to add item to the queue.
Instance of plugin for chaining.
Adds hooks for uploading items.
Function call that takes two parameters: prepare:CanvasPrepare, item:*
and
function must return true
if it was able to handle upload of item.
Instance of plugin for chaining.
Handle tick update
Upload all the textures and graphics to the GPU.
-
Either the container or display object to search for items to upload, the items to upload themselves,
or the callback function, if items have been added using prepare.add
.
Generated using TypeDoc
The prepare manager provides functionality to upload content to the GPU.
BasePrepare handles basic queuing functionality and is extended by PIXI.Prepare and {@link PIXI.CanvasPrepare} to provide preparation capabilities specific to their respective renderers.
// Create a sprite const sprite = PIXI.Sprite.from('something.png');
// Load object into GPU app.renderer.plugins.prepare.upload(sprite, () => {
})
PIXI