Base class for sprite batches

Hierarchy

Implements

Constructors

  • Parameters

    • context: WebGlRendererContext
    • id: string
    • capacity: number
    • depthOffset: number
    • yRenderOffset: number
    • enableAlphaMultiplcation: boolean
    • enforceBeginAndEnd: boolean

    Returns SpriteBatchWebGlBase

Properties

_setup: boolean
begun: boolean
capacity: number
colorArray: Uint8Array
colorBuffer: WebGLBuffer
dataArray: Float32Array
dataBuffer: WebGLBuffer
depthOffset: number
enableAlphaMultiplcation: boolean
enforceBeginAndEnd: boolean
id: string
inverseSpriteTextureSize: undefined | default
requiresSubpixels: boolean
shaderProgram: default
spriteCount: number
texCordBuffer: WebGLBuffer
texSprites: undefined | WebGLTexture
yRenderOffset: number

Methods

  • Parameters

    • tileX: number
    • tileY: number
    • spriteSize: number
    • sourceX: number
    • sourceY: number
    • sourceSize: number
    • offsetX: number = 0
    • offsetY: number = 0
    • red: number = 255
    • green: number = 255
    • blue: number = 255
    • alpha: number = 255

    Returns undefined | number

  • Returns void

  • Returns void

  • Returns void

  • Binds sprites to be included in the next render

    Returns

    number of sprites being rendered

    Returns number

  • Parameters

    • index: number

    Returns boolean

  • Parameters

    • x: number
    • y: number
    • tileScale: number
    • viewportWidth: number
    • viewportHeight: number

    Returns void

  • Returns void

  • Parameters

    • index: number
    • tileX: number
    • tileY: number
    • spriteSize: number
    • sourceX: number
    • sourceY: number
    • sourceSize: number
    • offsetX: number = 0
    • offsetY: number = 0
    • red: number = 255
    • green: number = 255
    • blue: number = 255
    • alpha: number = 255

    Returns void

  • Parameters

    Returns Promise<void>

Generated using TypeDoc