Closed evgeny-nadymov closed 4 years ago
@evgeny-nadymov Hi, according to the W3C MediaRecorder.stop() spec, it doesn't touch the stream when the method is called. It makes sense to me because there can be multiple stream processors attached to the recording stream at a time. So stopping the track will interrupt other stream processors.
I believe you need to do it manually in the onstop
event handler.
I might be wrong with the spec, so please tell me if the browser's native (other than opus-media-recorder) MediaRecorder.stop() clears the recording icons. Then I will fix the behavior.
Sorry, this is not a default behavior for the native recorder either.
Please add this line to MediaRecorder.stop() method in order to fix the issue.
this.stream.getAudioTracks().forEach(track => track.stop());