Texture

Module: engine.renderer.texture
new game.Texture(baseTexture, [x], [y], [width], [height])

Parameters:

  • baseTexture BaseTexture|String
  • x Number (optional)
  • y Number (optional)
  • width Number (optional)
  • height Number (optional)

Properties

_anchor Vector

(No description yet)

_offset Vector

(No description yet)

_trim Vector

(No description yet)

baseTexture BaseTexture

(No description yet)

height Number

(No description yet)

position Vector

(No description yet)

width Number

(No description yet)

Methods

clearCache() Static

(No description yet)

fromAsset(id) Texture Static

(No description yet)

Parameters:

  • id String
fromCanvas(canvas) Texture Static

(No description yet)

Parameters:

  • canvas HTMLCanvasElement
fromImage(path) Texture Static

(No description yet)

Parameters:

  • path String
remove()

Remove texture from cache.

Attributes

cache Object

(No description yet)