IAdapter
interface IAdapter
This interface describes all the DOM dependent calls that Pixi makes throughout its codebase Implementations of this interface can be used to make sure Pixi will work in any environment such as browser, web workers, and node
Summary
Properties from IAdapter
(width: number, height: number) => HTMLCanvasElement |
Returns a canvas object that can be used to create a webgl context. |
() => string |
Returns the current base URL For browser environments this is either the document.baseURI or window.location.href |
() => { userAgent : string } |
Returns a partial implementation of the browsers window.navigator |
() => typeof WebGLRenderingContext |
Returns a webgl rendering context. |
Public Properties
createCanvas: (width: number, height: number) => HTMLCanvasElement
Returns a canvas object that can be used to create a webgl context.
getBaseUrl: () => string
Returns the current base URL For browser environments this is either the document.baseURI or window.location.href
getWebGLRenderingContext: () => typeof WebGLRenderingContext
Returns a webgl rendering context.