Function: createImageSprite()
createImageSprite(
imagePath,renderContext,cameraEntity,vertexShaderName,fragmentShaderName):Promise<Sprite>
Defined in: rendering/utilities/create-image-sprite.ts:17
Creates a sprite using the provided image and render layer.
Parameters
imagePath
string
The path to the image to be used for the sprite.
renderContext
The render context used for shader retrieval.
cameraEntity
The camera entity for the renderable.
vertexShaderName
string = 'sprite.vert'
The vertex shader to use for the sprite material.
fragmentShaderName
string = 'sprite.frag'
The fragment shader to use for the sprite material.
Returns
Promise<Sprite>
The created sprite.