Constructor
new SpriteCommand(sprite)
Constructor
Parameters:
Name | Type | Description |
---|---|---|
sprite |
Sprite | A Sprite instance |
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 |
static isDefaultProgramLoaded() → {boolean}
Check if the default program is ready, otherwise the function load it
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 |
isOpaque() → {boolean}
Indicates if the command concern an opaque element
True if command must be in the opaque queue
boolean