emscripten-core / emscripten-core/emscripten

worker sent an error! Render.worker.js:1: Uncaught RuntimeError: Aborted(OOM)

Open
#19,596 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
27.6k
Forks
3.6k
Avg merge
1d 1h
Merged PRs (30d)
105

Description

we use Off-screen canvs render. loop play sent an error.
first: we use `emscripten_pthread_attr_settransferredcanvases(&attr, g_pHwd)` transfer a canvas control to the thread. And `pthread_create` a subThread .
second: we use `emscripten_set_main_loop_arg` loop render the yuv.
Third: `emscripten_cancel_main_loop` and destroy context.
loop the first/second/Third step.

The first question : we loop the first/second/Third step, chrome freezed when we play 4 video at once Within 400ms.
The second question : we loop the first/second/Third step. the worker sent an error when we play 1 video after 5min.
Render.js:1 worker sent an error! http://localhost:8060/Render.worker.js:1: Uncaught RuntimeError: Aborted(OOM). Build with -sASSERTIONS for more info.
Render.js:1 Aborted(OOM)
abort @ Render.js:1
abortOnCannotGrowMemory @ Render.js:1
_emscripten_resize_heap @ Render.js:1
$func82 @ Render.wasm:0x2714
$Fa @ Render.wasm:0x192e
$func104 @ Render.wasm:0x3186
$func171 @ Render.wasm:0x892f
invokeEntryPoint @ Render.js:1
handleMessage @ Render.worker.js:1

the demo is in the github:
https://github.com/yangfangfang1204/offscreen/tree/main/MultiOffscreenError

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.