Skip to content
This repository was archived by the owner on Jul 2, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib-minified/WebAudioRecorder.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions lib/WebAudioRecorder.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@
if (this.isRecording()) {
this.input.disconnect();
this.processor.disconnect();
this.processor.onaudioprocess = null;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

這影響著sannh?

Copy link
Author

@a8568730 a8568730 May 20, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我認為是為著 https://github.com/i3thuan5/web-audio-recorder-js/blob/master/lib/WebAudioRecorder.js#L98-L102 onaudioprocess 內底有送信號 worker.postMessage({ command: "record", buffer: buffer });,叫後壁錄音。

delete this.processor;
this.worker.postMessage({ command: "cancel" });
} else
Expand All @@ -126,6 +127,7 @@
if (this.isRecording()) {
this.input.disconnect();
this.processor.disconnect();
this.processor.onaudioprocess = null;
delete this.processor;
this.worker.postMessage({ command: "finish" });
} else
Expand Down