You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Default DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=1
* Add note about DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=1
* Add more details to the changelog
* Slightly improve formatting
* Update tests to use DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=1 mode
* Fix OffscreenCanvas lookup when compiling without pthreads enabled
* Fix test_other
if(!offscreenCanvas)offscreenCanvas=GL.offscreenCanvases[target]||(target=='canvas'&&Object.keys(GL.offscreenCanvases)[0]);// First looks up by DOM ID ("#myCanvasElement"), second looks up by DOM element name (first found element of type <canvas>)
303
-
if(offscreenCanvas)returnoffscreenCanvas;
304
-
292
+
// When compiling with OffscreenCanvas support and looking up a canvas to target,
293
+
// we first look up if the target Canvas has been transferred to OffscreenCanvas use.
294
+
// These transfers are represented/tracked by GL.offscreenCanvases object, which contain
295
+
// the OffscreenCanvas element for each regular Canvas element that has been transferred.
296
+
297
+
// Note that each pthread/worker have their own set of GL.offscreenCanvases. That is,
298
+
// when an OffscreenCanvas is transferred from a pthread/main thread to another pthread,
299
+
// it will move in the GL.offscreenCanvases array between threads. Hence GL.offscreenCanvases
300
+
// represents the set of OffscreenCanvases owned by the current calling thread.
301
+
302
+
// First check out the list of OffscreenCanvases by CSS selector ID ('#myCanvasID')
# Verify bug https://github.com/emscripten-core/emscripten/issues/4556: creating a WebGL context to Module.canvas without an ID explicitly assigned to it.
2590
+
# (this only makes sense in the old deprecated -s DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=0 mode)
# Tests that it is possible to render WebGL content on a <canvas> on the main thread, after it has once been used to render WebGL content in a pthread first
4239
4240
# -DTEST_MAIN_THREAD_EXPLICIT_COMMIT: Test the same (WebGL on main thread after pthread), but by using explicit .commit() to swap on the main thread instead of implicit "swap when rAF ends" logic
self.skipTest('This test is disabled because current OffscreenCanvas does not allow transfering it after a rendering context has been created for it.')
0 commit comments