Class

SpriteCommand

SpriteCommand(sprite)

Draw sprites

Constructor

new SpriteCommand(sprite)

Constructor
Parameters:
Name Type Description
sprite Sprite A Sprite instance

View Source Renderers/Commands/SpriteCommand.js, line 14

Extends

Methods

static draw(renderAPI, sprite)

Draw the given sprite
Parameters:
Name Type Description
renderAPI RenderAPI RenderAPI instance used to process the commands
sprite Sprite Sprite instance to draw

View Source Renderers/Commands/SpriteCommand.js, line 47

static isDefaultProgramLoaded() → {boolean}

Check if the default program is ready, otherwise the function load it

View Source Renderers/Commands/SpriteCommand.js, line 137

Return true if the default program is loaded
boolean

execute(renderAPI)

Execute the command
Parameters:
Name Type Description
renderAPI RenderAPI RenderAPI instance used to process the commands
Overrides:

View Source Renderers/Commands/SpriteCommand.js, line 37

isOpaque() → {boolean}

Indicates if the command concern an opaque element
Overrides:

View Source Renderers/Commands/SpriteCommand.js, line 176

True if command must be in the opaque queue
boolean