summaryrefslogtreecommitdiff
path: root/platform/javascript
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-08-10 06:24:19 +0200
committerGitHub <noreply@github.com>2019-08-10 06:24:19 +0200
commit3c7327da332c6bf56f8c2a8e601a13fa718ede05 (patch)
tree98e39cd79ced9c39c38d93ff70a2c5ef3eb08299 /platform/javascript
parent71a6d2cd17b9b48027a6a36b4e7b8adee0eb373c (diff)
parent69f7263cd8990b39e4c1cc678b2d0f57686b07b7 (diff)
Merge pull request #31253 from SaracenOne/audio_capture_javascript
Fix audio capture naming in web export
Diffstat (limited to 'platform/javascript')
-rw-r--r--platform/javascript/audio_driver_javascript.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/platform/javascript/audio_driver_javascript.cpp b/platform/javascript/audio_driver_javascript.cpp
index 163826f828..b359699d3a 100644
--- a/platform/javascript/audio_driver_javascript.cpp
+++ b/platform/javascript/audio_driver_javascript.cpp
@@ -63,7 +63,7 @@ void AudioDriverJavaScript::mix_to_js() {
void AudioDriverJavaScript::process_capture(float sample) {
int32_t sample32 = int32_t(sample * 32768.f) * (1U << 16);
- input_buffer_write(sample32);
+ capture_buffer_write(sample32);
}
Error AudioDriverJavaScript::init() {
@@ -198,7 +198,7 @@ void AudioDriverJavaScript::finish() {
Error AudioDriverJavaScript::capture_start() {
- input_buffer_init(buffer_length);
+ capture_buffer_init(buffer_length);
/* clang-format off */
EM_ASM({
@@ -245,8 +245,6 @@ Error AudioDriverJavaScript::capture_stop() {
});
/* clang-format on */
- input_buffer.clear();
-
return OK;
}