CanvasTexture
此内容尚不支持你的语言。
Defined in: asset/canvasTexture.ts:26
A texture backed by a canvas someone else draws on.
Properties
Section titled “Properties”handle
Section titled “handle”
readonlyhandle:number
Defined in: asset/canvasTexture.ts:28
The engine texture handle — stable across every update.
height
Section titled “height”
readonlyheight:number
Defined in: asset/canvasTexture.ts:31
readonlywidth:number
Defined in: asset/canvasTexture.ts:30
Size of the last upload. Follows the source when it is resized.
Methods
Section titled “Methods”destroy()
Section titled “destroy()”destroy():
void
Defined in: asset/canvasTexture.ts:36
Release the GL texture. The handle is dead afterwards.
Returns
Section titled “Returns”void
update()
Section titled “update()”update():
void
Defined in: asset/canvasTexture.ts:34
Re-take the source’s current content. Cheap to call, not free: one
texImage2D of the whole surface. Callers gate on visibility.
Returns
Section titled “Returns”void