Skip to content

Commit 659323a

Browse files
committed
Managed audio playback (if memory is less than 4GB)
1 parent 466a447 commit 659323a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/audio_worklet.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ function createWasmAudioWorkletProcessor(audioParams) {
129129

130130
// Copy parameters descriptor structs and data to Wasm
131131
paramsPtr = dataPtr;
132-
k = paramsPtr >> 2;
132+
k = paramsPtr >>> 2;
133133
dataPtr += numParams * {{{ C_STRUCTS.AudioParamFrame.__size__ }}};
134134
for (i = 0; paramArray = parameters[i++];) {
135135
// Write the AudioParamFrame struct instance
@@ -144,7 +144,7 @@ function createWasmAudioWorkletProcessor(audioParams) {
144144
// Copy output audio descriptor structs to Wasm (note that dataPtr after
145145
// the struct offsets should now be 16-byte aligned).
146146
outputsPtr = dataPtr;
147-
k = outputsPtr >> 2;
147+
k = outputsPtr >>> 2;
148148
dataPtr += numOutputs * {{{ C_STRUCTS.AudioSampleFrame.__size__ }}};
149149
for (i of outputList) {
150150
// Write the AudioSampleFrame struct instance

0 commit comments

Comments
 (0)