Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upImplement HTMLCanvasElement's transferControlToOffscreen API #24273
Labels
Comments
|
The comment at #24272 (comment) applies to this as well. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The canvas API supports taking an existing HTMLCanvasElement, calling the
transferControlToOffscreenmethod and obtaining a newOffscreenCanvaswhich wraps the existing canvas state. The existing canvas element changes its mode to the placeholder mode, and its content is only updated when calling thecommitmethod of the new OffscreenCanvas.WebIDL:
Spec:
Code:
components/script/dom/webidls/HTMLCanvasElement.webidlcomponents/script/dom/webidls/OffscreenCanvasRenderingContext2D.webidlcomponents/script/dom/htmlcanvaselement.rscomponents/script/dom/offscreenrenderingcontext2d.rsTests:
./mach test-wpt tests/wpt/web-platform-tests/offscreen-canvas/the-canvas-element