Creates a Canvas element of the given size.
Public methods | |
---|---|
private | clear(): void |
public | resize(width: number, height: number): void |
public | destroy(): void |
public | width(): void |
public | height(): void |
private | clear(): void |
public | resize(width: number, height: number): void |
public | destroy(): void |
public | width(): void |
public | height(): void |
Name | Type | Attribute | Description |
---|---|---|---|
canvas | HTMLCanvasElement | public | The Canvas object that belongs to this CanvasRenderTarget. |
context | CanvasRenderingContext2D | public | A CanvasRenderingContext2D object representing a two-dimensional rendering context. |
canvas | HTMLCanvasElement | public | The Canvas object that belongs to this CanvasRenderTarget. |
context | CanvasRenderingContext2D | public | A CanvasRenderingContext2D object representing a two-dimensional rendering context. |
Clears the canvas that was created by the CanvasRenderTarget class.
void
Resizes the canvas to the specified width and height.
Name | Type | Attribute | Description |
---|---|---|---|
width | the new width of the canvas |
||
height | the new height of the canvas |
void
Destroys this canvas.
void
The width of the canvas buffer in pixels.
void
The height of the canvas buffer in pixels.
void
Clears the canvas that was created by the CanvasRenderTarget class.
void
Resizes the canvas to the specified width and height.
Name | Type | Attribute | Description |
---|---|---|---|
width | the new width of the canvas |
||
height | the new height of the canvas |
void
Destroys this canvas.
void
The width of the canvas buffer in pixels.
void
The height of the canvas buffer in pixels.
void
{ "comment": "/**\n * Creates a Canvas element of the given size.\n *\n * @class\n * @memberof PIXI\n */", "meta": { "range": [ 165, 2371 ], "filename": "CanvasRenderTarget.js", "lineno": 11, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100022191", "name": "CanvasRenderTarget", "type": "ClassDeclaration", "paramnames": [ "width", "height", "resolution" ] } }, "classdesc": "Creates a Canvas element of the given size.
", "kind": "class", "memberof": "PIXI", "name": "CanvasRenderTarget", "longname": "PIXI.CanvasRenderTarget", "scope": "static", "params": [ { "type": { "names": [ "number" ] }, "description": "the width for the newly created canvas
", "name": "width" }, { "type": { "names": [ "number" ] }, "description": "the height for the newly created canvas
", "name": "height" }, { "type": { "names": [ "number" ] }, "optional": true, "defaultvalue": 1, "description": "The resolution / device pixel ratio of the canvas
", "name": "resolution" } ], "___id": "T000002R002070", "___s": true, "$methods": [ { "comment": "/**\n * Clears the canvas that was created by the CanvasRenderTarget class.\n *\n * @private\n */", "meta": { "range": [ 1206, 1355 ], "filename": "CanvasRenderTarget.js", "lineno": 44, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100022240", "name": "CanvasRenderTarget#clear", "type": "MethodDefinition", "paramnames": [] }, "vars": { "": null } }, "description": "Clears the canvas that was created by the CanvasRenderTarget class.
", "access": "private", "name": "clear", "longname": "PIXI.CanvasRenderTarget#clear", "kind": "function", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "params": [], "___id": "T000002R002077", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetclear", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * Resizes the canvas to the specified width and height.\n *\n * @param {number} width - the new width of the canvas\n * @param {number} height - the new height of the canvas\n */", "meta": { "range": [ 1565, 1706 ], "filename": "CanvasRenderTarget.js", "lineno": 56, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100022276", "name": "CanvasRenderTarget#resize", "type": "MethodDefinition", "paramnames": [ "width", "height" ] }, "vars": { "": null } }, "description": "Resizes the canvas to the specified width and height.
", "params": [ { "type": { "names": [ "number" ] }, "description": "the new width of the canvas
", "name": "width" }, { "type": { "names": [ "number" ] }, "description": "the new height of the canvas
", "name": "height" } ], "name": "resize", "longname": "PIXI.CanvasRenderTarget#resize", "kind": "function", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "___id": "T000002R002078", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetresize", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * Destroys this canvas.\n *\n */", "meta": { "range": [ 1764, 1842 ], "filename": "CanvasRenderTarget.js", "lineno": 66, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100022306", "name": "CanvasRenderTarget#destroy", "type": "MethodDefinition", "paramnames": [] }, "vars": { "": null } }, "description": "Destroys this canvas.
", "name": "destroy", "longname": "PIXI.CanvasRenderTarget#destroy", "kind": "function", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "params": [], "___id": "T000002R002081", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetdestroy", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * The width of the canvas buffer in pixels.\n *\n * @member {number}\n */", "meta": { "range": [ 1944, 2001 ], "filename": "CanvasRenderTarget.js", "lineno": 77, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100022322", "name": "CanvasRenderTarget#width", "type": "MethodDefinition", "paramnames": [] }, "vars": { "": null } }, "description": "The width of the canvas buffer in pixels.
", "kind": "member", "type": { "names": [ "number" ] }, "name": "width", "longname": "PIXI.CanvasRenderTarget#width", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "params": [], "___id": "T000002R002084", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetwidth", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * The height of the canvas buffer in pixels.\n *\n * @member {number}\n */", "meta": { "range": [ 2206, 2265 ], "filename": "CanvasRenderTarget.js", "lineno": 92, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100022345", "name": "CanvasRenderTarget#height", "type": "MethodDefinition", "paramnames": [] }, "vars": { "": null } }, "description": "The height of the canvas buffer in pixels.
", "kind": "member", "type": { "names": [ "number" ] }, "name": "height", "longname": "PIXI.CanvasRenderTarget#height", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "params": [], "___id": "T000002R002087", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetheight", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * Clears the canvas that was created by the CanvasRenderTarget class.\n *\n * @private\n */", "meta": { "range": [ 1206, 1355 ], "filename": "CanvasRenderTarget.js", "lineno": 44, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100096919", "name": "CanvasRenderTarget#clear", "type": "MethodDefinition", "paramnames": [] }, "vars": { "": null } }, "description": "Clears the canvas that was created by the CanvasRenderTarget class.
", "access": "private", "name": "clear", "longname": "PIXI.CanvasRenderTarget#clear", "kind": "function", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "params": [], "___id": "T000002R009011", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetclear", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * Resizes the canvas to the specified width and height.\n *\n * @param {number} width - the new width of the canvas\n * @param {number} height - the new height of the canvas\n */", "meta": { "range": [ 1565, 1706 ], "filename": "CanvasRenderTarget.js", "lineno": 56, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100096955", "name": "CanvasRenderTarget#resize", "type": "MethodDefinition", "paramnames": [ "width", "height" ] }, "vars": { "": null } }, "description": "Resizes the canvas to the specified width and height.
", "params": [ { "type": { "names": [ "number" ] }, "description": "the new width of the canvas
", "name": "width" }, { "type": { "names": [ "number" ] }, "description": "the new height of the canvas
", "name": "height" } ], "name": "resize", "longname": "PIXI.CanvasRenderTarget#resize", "kind": "function", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "___id": "T000002R009012", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetresize", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * Destroys this canvas.\n *\n */", "meta": { "range": [ 1764, 1842 ], "filename": "CanvasRenderTarget.js", "lineno": 66, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100096985", "name": "CanvasRenderTarget#destroy", "type": "MethodDefinition", "paramnames": [] }, "vars": { "": null } }, "description": "Destroys this canvas.
", "name": "destroy", "longname": "PIXI.CanvasRenderTarget#destroy", "kind": "function", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "params": [], "___id": "T000002R009015", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetdestroy", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * The width of the canvas buffer in pixels.\n *\n * @member {number}\n */", "meta": { "range": [ 1944, 2001 ], "filename": "CanvasRenderTarget.js", "lineno": 77, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100097001", "name": "CanvasRenderTarget#width", "type": "MethodDefinition", "paramnames": [] }, "vars": { "": null } }, "description": "The width of the canvas buffer in pixels.
", "kind": "member", "type": { "names": [ "number" ] }, "name": "width", "longname": "PIXI.CanvasRenderTarget#width", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "params": [], "___id": "T000002R009018", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetwidth", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * The height of the canvas buffer in pixels.\n *\n * @member {number}\n */", "meta": { "range": [ 2206, 2265 ], "filename": "CanvasRenderTarget.js", "lineno": 92, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": { "id": "astnode100097024", "name": "CanvasRenderTarget#height", "type": "MethodDefinition", "paramnames": [] }, "vars": { "": null } }, "description": "The height of the canvas buffer in pixels.
", "kind": "member", "type": { "names": [ "number" ] }, "name": "height", "longname": "PIXI.CanvasRenderTarget#height", "memberof": "PIXI.CanvasRenderTarget", "scope": "instance", "params": [], "___id": "T000002R009021", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetheight", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" } ], "$attributes": [ { "comment": "/**\n * The Canvas object that belongs to this CanvasRenderTarget.\n *\n * @member {HTMLCanvasElement} PIXI.CanvasRenderTarget#canvas\n */", "meta": { "range": [ 497, 663 ], "filename": "CanvasRenderTarget.js", "lineno": 20, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": {} }, "description": "The Canvas object that belongs to this CanvasRenderTarget.
", "kind": "member", "name": "canvas", "type": { "names": [ "HTMLCanvasElement" ] }, "memberof": "PIXI.CanvasRenderTarget", "longname": "PIXI.CanvasRenderTarget#canvas", "scope": "instance", "___id": "T000002R002072", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetcanvas", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * A CanvasRenderingContext2D object representing a two-dimensional rendering context.\n *\n * @member {CanvasRenderingContext2D} PIXI.CanvasRenderTarget#context\n */", "meta": { "range": [ 729, 928 ], "filename": "CanvasRenderTarget.js", "lineno": 27, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": {} }, "description": "A CanvasRenderingContext2D object representing a two-dimensional rendering context.
", "kind": "member", "name": "context", "type": { "names": [ "CanvasRenderingContext2D" ] }, "memberof": "PIXI.CanvasRenderTarget", "longname": "PIXI.CanvasRenderTarget#context", "scope": "instance", "___id": "T000002R002074", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetcontext", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * The Canvas object that belongs to this CanvasRenderTarget.\n *\n * @member {HTMLCanvasElement} PIXI.CanvasRenderTarget#canvas\n */", "meta": { "range": [ 497, 663 ], "filename": "CanvasRenderTarget.js", "lineno": 20, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": {} }, "description": "The Canvas object that belongs to this CanvasRenderTarget.
", "kind": "member", "name": "canvas", "type": { "names": [ "HTMLCanvasElement" ] }, "memberof": "PIXI.CanvasRenderTarget", "longname": "PIXI.CanvasRenderTarget#canvas", "scope": "instance", "___id": "T000002R009006", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetcanvas", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }, { "comment": "/**\n * A CanvasRenderingContext2D object representing a two-dimensional rendering context.\n *\n * @member {CanvasRenderingContext2D} PIXI.CanvasRenderTarget#context\n */", "meta": { "range": [ 729, 928 ], "filename": "CanvasRenderTarget.js", "lineno": 27, "path": "C:\\Users\\beaujeup\\projects\\jsdoc-template\\examples\\pixi.js\\pixi.js-repo\\src\\core\\renderers\\canvas\\utils", "code": {} }, "description": "A CanvasRenderingContext2D object representing a two-dimensional rendering context.
", "kind": "member", "name": "context", "type": { "names": [ "CanvasRenderingContext2D" ] }, "memberof": "PIXI.CanvasRenderTarget", "longname": "PIXI.CanvasRenderTarget#context", "scope": "instance", "___id": "T000002R009008", "___s": true, "skip": true, "slug": "PIXI.CanvasRenderTargetcontext", "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" } ], "$staticmethods": [], "$staticproperties": [], "$augments": [], "$augmentedBy": [], "filepath": "core\\renderers\\canvas\\utils\\CanvasRenderTarget.js" }