File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 1010// 2. post invocation from audio worklet thread to main thread
1111_Atomic uint32_t callbackCount = 0 ;
1212
13+ EMSCRIPTEN_WEBAUDIO_T context ;
14+
1315void do_exit () {
1416 emscripten_out ("do_exit" );
1517 assert (callbackCount == 16 );
18+ emscripten_destroy_audio_context (context );
1619 emscripten_force_exit (0 );
1720}
1821
@@ -198,7 +201,7 @@ uint8_t wasmAudioWorkletStack[4096];
198201
199202int main () {
200203 // Create an audio context
201- EMSCRIPTEN_WEBAUDIO_T context = emscripten_create_audio_context (0 /* use default constructor options */ );
204+ context = emscripten_create_audio_context (0 /* use default constructor options */ );
202205
203206 // and kick off Audio Worklet scope initialization, which shares the Wasm
204207 // Module and Memory to the AudioWorklet scope and initializes its stack.
You can’t perform that action at this time.
0 commit comments