BaseTexture

Module: engine.renderer.texture
new game.BaseTexture(source, loadCallback)

Parameters:

  • source HTMLImageElement|HTMLCanvasElement
  • loadCallback Function

Properties

_id Number|String

(No description yet)

_loadCallback Function

(No description yet)

height Number

(No description yet)

loaded Boolean (Default: false)

(No description yet)

source HTMLImageElement|HTMLCanvasElement

(No description yet)

width Number

(No description yet)

Methods

_onerror()

(No description yet)

_onload()

(No description yet)

clearCache() Static

(No description yet)

fromAsset(id) BaseTexture Static

(No description yet)

Parameters:

  • id String
fromCanvas(canvas) BaseTexture Static

(No description yet)

Parameters:

  • canvas HTMLCanvasElement
fromImage(path, loadCallback) BaseTexture Static

(No description yet)

Parameters:

  • path String
  • loadCallback Function
remove()

Remove base texture from cache.

Attributes

_id Number

(No description yet)

cache Object

(No description yet)

crossOrigin String (Default: '')

Default crossOrigin property to use in all Image sources