react-native-audio-api 0.12.0-nightly-6a44b58-20260126 → 0.12.0-nightly-3254662-20260127
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/RNAudioAPI.podspec +8 -0
- package/android/src/main/cpp/audioapi/CMakeLists.txt +6 -13
- package/android/src/main/cpp/audioapi/android/core/AndroidAudioRecorder.cpp +12 -1
- package/common/cpp/audioapi/HostObjects/inputs/AudioRecorderHostObject.cpp +2 -1
- package/common/cpp/audioapi/core/AudioNode.cpp +2 -2
- package/common/cpp/audioapi/core/utils/AudioFileWriter.cpp +2 -3
- package/common/cpp/audioapi/core/utils/AudioRecorderCallback.cpp +2 -3
- package/common/cpp/audioapi/jsi/JsiUtils.cpp +21 -0
- package/common/cpp/audioapi/jsi/JsiUtils.h +17 -0
- package/{android/src/main/cpp/audioapi/android/core → common/cpp/audioapi}/utils/MiniaudioImplementation.cpp +1 -2
- package/ios/audioapi/ios/core/utils/AudioDecoder.mm +1 -3
- package/lib/commonjs/core/AudioRecorder.js +1 -1
- package/lib/commonjs/core/AudioRecorder.js.map +1 -1
- package/lib/module/core/AudioRecorder.js +1 -1
- package/lib/module/core/AudioRecorder.js.map +1 -1
- package/package.json +1 -1
- package/src/core/AudioRecorder.ts +1 -1
package/RNAudioAPI.podspec
CHANGED
|
@@ -46,6 +46,14 @@ Pod::Spec.new do |s|
|
|
|
46
46
|
sss.header_mappings_dir = "common/cpp/audioapi/dsp"
|
|
47
47
|
sss.compiler_flags = "-O3"
|
|
48
48
|
end
|
|
49
|
+
|
|
50
|
+
# compile miniaudio implementation file as objective-c++
|
|
51
|
+
ss.subspec "miniaudio_impl" do |sss|
|
|
52
|
+
sss.source_files = "common/cpp/audioapi/utils/MiniaudioImplementation.cpp"
|
|
53
|
+
sss.header_dir = "audioapi/libs"
|
|
54
|
+
sss.header_mappings_dir = "common/cpp/audioapi/libs"
|
|
55
|
+
sss.compiler_flags = "-x objective-c++"
|
|
56
|
+
end
|
|
49
57
|
end
|
|
50
58
|
|
|
51
59
|
if worklets_enabled
|
|
@@ -99,23 +99,16 @@ target_include_directories(
|
|
|
99
99
|
${INCLUDE_LIBRARIES}
|
|
100
100
|
)
|
|
101
101
|
|
|
102
|
-
if(ReactAndroid_VERSION_MINOR GREATER_EQUAL 76)
|
|
103
|
-
set(RN_VERSION_LINK_LIBRARIES
|
|
104
|
-
ReactAndroid::reactnative
|
|
105
|
-
)
|
|
106
|
-
else()
|
|
107
|
-
set(RN_VERSION_LINK_LIBRARIES
|
|
108
|
-
ReactAndroid::folly_runtime
|
|
109
|
-
ReactAndroid::react_nativemodule_core
|
|
110
|
-
ReactAndroid::glog
|
|
111
|
-
ReactAndroid::reactnativejni
|
|
112
|
-
)
|
|
113
|
-
endif()
|
|
114
|
-
|
|
115
102
|
set(RN_VERSION_LINK_LIBRARIES
|
|
116
103
|
ReactAndroid::reactnative
|
|
117
104
|
)
|
|
118
105
|
|
|
106
|
+
target_compile_options(
|
|
107
|
+
react-native-audio-api
|
|
108
|
+
PRIVATE
|
|
109
|
+
-Wno-mismatched-tags
|
|
110
|
+
)
|
|
111
|
+
|
|
119
112
|
if(RN_AUDIO_API_WORKLETS_ENABLED)
|
|
120
113
|
target_compile_definitions(
|
|
121
114
|
react-native-audio-api
|
|
@@ -19,6 +19,8 @@
|
|
|
19
19
|
|
|
20
20
|
#include <memory>
|
|
21
21
|
#include <string>
|
|
22
|
+
#include <unordered_map>
|
|
23
|
+
#include <utility>
|
|
22
24
|
|
|
23
25
|
namespace audioapi {
|
|
24
26
|
|
|
@@ -420,7 +422,16 @@ void AndroidAudioRecorder::onErrorAfterClose(oboe::AudioStream *stream, oboe::Re
|
|
|
420
422
|
auto streamResult = openAudioStream();
|
|
421
423
|
|
|
422
424
|
if (!streamResult.is_ok()) {
|
|
423
|
-
|
|
425
|
+
uint64_t callbackId = errorCallbackId_.load(std::memory_order_acquire);
|
|
426
|
+
|
|
427
|
+
if (audioEventHandlerRegistry_ == nullptr || callbackId == 0) {
|
|
428
|
+
return;
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
std::string message = "Android recorder error: " + streamResult.unwrap_err();
|
|
432
|
+
std::unordered_map<std::string, EventValue> eventPayload{{"message", std::move(message)}};
|
|
433
|
+
audioEventHandlerRegistry_->invokeHandlerWithEventBody(
|
|
434
|
+
"recorderError", callbackId, eventPayload);
|
|
424
435
|
return;
|
|
425
436
|
}
|
|
426
437
|
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
#include <audioapi/core/sources/AudioBuffer.h>
|
|
7
7
|
#include <audioapi/events/AudioEventHandlerRegistry.h>
|
|
8
8
|
#include <audioapi/utils/AudioFileProperties.h>
|
|
9
|
+
#include <audioapi/jsi/JsiUtils.h>
|
|
9
10
|
#ifdef ANDROID
|
|
10
11
|
#include <audioapi/android/core/AndroidAudioRecorder.h>
|
|
11
12
|
#else
|
|
@@ -41,7 +42,7 @@ AudioRecorderHostObject::AudioRecorderHostObject(
|
|
|
41
42
|
}
|
|
42
43
|
|
|
43
44
|
JSI_HOST_FUNCTION_IMPL(AudioRecorderHostObject, start) {
|
|
44
|
-
auto fileNameOverride =
|
|
45
|
+
auto fileNameOverride = jsiutils::argToString(runtime, args, count, 0, "");
|
|
45
46
|
auto result = audioRecorder_->start(fileNameOverride);
|
|
46
47
|
auto jsResult = jsi::Object(runtime);
|
|
47
48
|
|
|
@@ -17,8 +17,8 @@ AudioNode::AudioNode(std::shared_ptr<BaseAudioContext> context) : context_(conte
|
|
|
17
17
|
}
|
|
18
18
|
|
|
19
19
|
AudioNode::AudioNode(std::shared_ptr<BaseAudioContext> context, const AudioNodeOptions &options)
|
|
20
|
-
:
|
|
21
|
-
|
|
20
|
+
: channelCount_(options.channelCount),
|
|
21
|
+
context_(context),
|
|
22
22
|
channelCountMode_(options.channelCountMode),
|
|
23
23
|
channelInterpretation_(options.channelInterpretation) {
|
|
24
24
|
audioBus_ =
|
|
@@ -29,9 +29,8 @@ void AudioFileWriter::invokeOnErrorCallback(const std::string &message) {
|
|
|
29
29
|
return;
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
std::unordered_map<std::string, EventValue> eventPayload = {};
|
|
33
|
-
|
|
34
|
-
audioEventHandlerRegistry_->invokeHandlerWithEventBody("error", callbackId, eventPayload);
|
|
32
|
+
std::unordered_map<std::string, EventValue> eventPayload = {{"message", message}};
|
|
33
|
+
audioEventHandlerRegistry_->invokeHandlerWithEventBody("recorderError", callbackId, eventPayload);
|
|
35
34
|
}
|
|
36
35
|
|
|
37
36
|
bool AudioFileWriter::isFileOpen() {
|
|
@@ -97,9 +97,8 @@ void AudioRecorderCallback::invokeOnErrorCallback(const std::string &message) {
|
|
|
97
97
|
return;
|
|
98
98
|
}
|
|
99
99
|
|
|
100
|
-
std::unordered_map<std::string, EventValue> eventPayload = {};
|
|
101
|
-
|
|
102
|
-
audioEventHandlerRegistry_->invokeHandlerWithEventBody("error", callbackId, eventPayload);
|
|
100
|
+
std::unordered_map<std::string, EventValue> eventPayload = {{"message", message}};
|
|
101
|
+
audioEventHandlerRegistry_->invokeHandlerWithEventBody("recorderError", callbackId, eventPayload);
|
|
103
102
|
}
|
|
104
103
|
|
|
105
104
|
} // namespace audioapi
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
#include <audioapi/jsi/JsiUtils.h>
|
|
2
|
+
#include <string>
|
|
3
|
+
|
|
4
|
+
namespace audioapi::jsiutils {
|
|
5
|
+
|
|
6
|
+
using namespace facebook;
|
|
7
|
+
|
|
8
|
+
std::string argToString(
|
|
9
|
+
jsi::Runtime &runtime,
|
|
10
|
+
const jsi::Value *args,
|
|
11
|
+
size_t count,
|
|
12
|
+
size_t index,
|
|
13
|
+
const std::string &defaultValue) {
|
|
14
|
+
if (index < count && args[index].isString()) {
|
|
15
|
+
return args[index].asString(runtime).utf8(runtime);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
return defaultValue;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
} // namespace audioapi::jsiutils
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
#pragma once
|
|
2
|
+
|
|
3
|
+
#include <jsi/jsi.h>
|
|
4
|
+
#include <string>
|
|
5
|
+
|
|
6
|
+
namespace audioapi::jsiutils {
|
|
7
|
+
|
|
8
|
+
using namespace facebook;
|
|
9
|
+
|
|
10
|
+
std::string argToString(
|
|
11
|
+
jsi::Runtime &runtime,
|
|
12
|
+
const jsi::Value *args,
|
|
13
|
+
size_t count,
|
|
14
|
+
size_t index,
|
|
15
|
+
const std::string &defaultValue = "");
|
|
16
|
+
|
|
17
|
+
} // namespace audioapi::jsiutils
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
/// Miniaudio implementation
|
|
1
|
+
/// Miniaudio implementation
|
|
2
2
|
/// this define tells the miniaudio to also include the definitions and not only declarations.
|
|
3
3
|
/// Which should be done only once in the whole project.
|
|
4
4
|
/// This make its safe to include the header file in multiple places, without causing multiple definition errors.
|
|
5
|
-
/// TODO: Consider moving this file to common scope to re-use the miniaudio also for iOS platform.
|
|
6
5
|
#define MINIAUDIO_IMPLEMENTATION
|
|
7
6
|
#define MA_DEBUG_OUTPUT
|
|
8
7
|
#include <audioapi/libs/miniaudio/miniaudio.h>
|
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
#define MINIAUDIO_IMPLEMENTATION
|
|
2
|
-
#import <audioapi/libs/miniaudio/miniaudio.h>
|
|
3
|
-
|
|
4
1
|
#include <audioapi/libs/miniaudio/decoders/libopus/miniaudio_libopus.h>
|
|
5
2
|
#include <audioapi/libs/miniaudio/decoders/libvorbis/miniaudio_libvorbis.h>
|
|
3
|
+
#include <audioapi/libs/miniaudio/miniaudio.h>
|
|
6
4
|
|
|
7
5
|
#include <audioapi/core/sources/AudioBuffer.h>
|
|
8
6
|
#include <audioapi/core/utils/AudioDecoder.h>
|
|
@@ -16,7 +16,7 @@ function withDefaultOptions(inOptions) {
|
|
|
16
16
|
return {
|
|
17
17
|
directory: _types.FileDirectory.Cache,
|
|
18
18
|
subDirectory: 'AudioAPI',
|
|
19
|
-
fileNamePrefix: '
|
|
19
|
+
fileNamePrefix: 'recording',
|
|
20
20
|
channelCount: 2,
|
|
21
21
|
format: _types.FileFormat.M4A,
|
|
22
22
|
batchDurationSeconds: 0,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_errors","require","_events","_types","_filePresets","_interopRequireDefault","_AudioBuffer","e","__esModule","default","withDefaultOptions","inOptions","directory","FileDirectory","Cache","subDirectory","fileNamePrefix","channelCount","format","FileFormat","M4A","batchDurationSeconds","preset","FilePreset","High","androidFlushIntervalMs","AudioRecorder","onAudioReadySubscription","onErrorSubscription","options_","isFileOutputEnabled","audioEventEmitter","AudioEventEmitter","global","constructor","recorder","createAudioRecorder","enableFileOutput","options","parsedOptions","result","disableFileOutput","start","status","path","fileNameOverride","stop","pause","resume","connect","node","wasConnected","AudioApiError","getNode","disconnect","onAudioReady","callback","clearOnAudioReady","remove","addAudioEventListener","event","audioBuffer","AudioBuffer","buffer","setOnAudioReady","sampleRate","bufferLength","callbackId","subscriptionId","isRecording","isPaused","getCurrentDuration","onError","clearOnError","setOnError","exports"],"sourceRoot":"../../../src","sources":["core/AudioRecorder.ts"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AACA,IAAAC,OAAA,GAAAD,OAAA;AAMA,IAAAE,MAAA,GAAAF,OAAA;AASA,IAAAG,YAAA,GAAAC,sBAAA,CAAAJ,OAAA;AACA,IAAAK,YAAA,GAAAD,sBAAA,CAAAJ,OAAA;AAAwC,SAAAI,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAGxC;AACA;AACA,SAASG,kBAAkBA,CACzBC,SAAmC,EACC;EACpC,OAAO;IACLC,SAAS,EAAEC,oBAAa,CAACC,KAAK;IAC9BC,YAAY,EAAE,UAAU;IACxBC,cAAc,EAAE,
|
|
1
|
+
{"version":3,"names":["_errors","require","_events","_types","_filePresets","_interopRequireDefault","_AudioBuffer","e","__esModule","default","withDefaultOptions","inOptions","directory","FileDirectory","Cache","subDirectory","fileNamePrefix","channelCount","format","FileFormat","M4A","batchDurationSeconds","preset","FilePreset","High","androidFlushIntervalMs","AudioRecorder","onAudioReadySubscription","onErrorSubscription","options_","isFileOutputEnabled","audioEventEmitter","AudioEventEmitter","global","constructor","recorder","createAudioRecorder","enableFileOutput","options","parsedOptions","result","disableFileOutput","start","status","path","fileNameOverride","stop","pause","resume","connect","node","wasConnected","AudioApiError","getNode","disconnect","onAudioReady","callback","clearOnAudioReady","remove","addAudioEventListener","event","audioBuffer","AudioBuffer","buffer","setOnAudioReady","sampleRate","bufferLength","callbackId","subscriptionId","isRecording","isPaused","getCurrentDuration","onError","clearOnError","setOnError","exports"],"sourceRoot":"../../../src","sources":["core/AudioRecorder.ts"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AACA,IAAAC,OAAA,GAAAD,OAAA;AAMA,IAAAE,MAAA,GAAAF,OAAA;AASA,IAAAG,YAAA,GAAAC,sBAAA,CAAAJ,OAAA;AACA,IAAAK,YAAA,GAAAD,sBAAA,CAAAJ,OAAA;AAAwC,SAAAI,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAGxC;AACA;AACA,SAASG,kBAAkBA,CACzBC,SAAmC,EACC;EACpC,OAAO;IACLC,SAAS,EAAEC,oBAAa,CAACC,KAAK;IAC9BC,YAAY,EAAE,UAAU;IACxBC,cAAc,EAAE,WAAW;IAC3BC,YAAY,EAAE,CAAC;IACfC,MAAM,EAAEC,iBAAU,CAACC,GAAG;IACtBC,oBAAoB,EAAE,CAAC;IACvBC,MAAM,EAAEC,oBAAU,CAACC,IAAI;IACvBC,sBAAsB,EAAE,GAAG;IAC3B,GAAGd;EACL,CAAC;AACH;AAE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AA,EAAS;IACnB,IAAI,CAAC,IAAI,CAAC7C,mBAAmB,EAAE;MAC7B;IACF;IAEA,IAAI,CAACO,QAAQ,CAACsC,YAAY,CAAC,CAAC;IAE5B,IAAI,CAAC7C,mBAAmB,CAAC8B,MAAM,CAAC,CAAC;IACjC,IAAI,CAAC9B,mBAAmB,GAAG,IAAI;EACjC;AACF;AAAC+C,OAAA,CAAAlE,OAAA,GAAAiB,aAAA","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["AudioApiError","AudioEventEmitter","FileDirectory","FileFormat","FilePreset","AudioBuffer","withDefaultOptions","inOptions","directory","Cache","subDirectory","fileNamePrefix","channelCount","format","M4A","batchDurationSeconds","preset","High","androidFlushIntervalMs","AudioRecorder","onAudioReadySubscription","onErrorSubscription","options_","isFileOutputEnabled","audioEventEmitter","global","constructor","recorder","createAudioRecorder","enableFileOutput","options","parsedOptions","result","disableFileOutput","start","status","path","fileNameOverride","stop","pause","resume","connect","node","wasConnected","getNode","disconnect","onAudioReady","callback","clearOnAudioReady","remove","addAudioEventListener","event","audioBuffer","buffer","setOnAudioReady","sampleRate","bufferLength","callbackId","subscriptionId","isRecording","isPaused","getCurrentDuration","onError","clearOnError","setOnError"],"sourceRoot":"../../../src","sources":["core/AudioRecorder.ts"],"mappings":";;AAAA,SAASA,aAAa,QAAQ,oBAAW;AACzC,SAASC,iBAAiB,QAAgC,oBAAW;AAMrE,SAIEC,aAAa,EACbC,UAAU,QAGL,aAAU;AACjB,OAAOC,UAAU,MAAM,yBAAsB;AAC7C,OAAOC,WAAW,MAAM,kBAAe;AAGvC;AACA;AACA,SAASC,kBAAkBA,CACzBC,SAAmC,EACC;EACpC,OAAO;IACLC,SAAS,EAAEN,aAAa,CAACO,KAAK;IAC9BC,YAAY,EAAE,UAAU;IACxBC,cAAc,EAAE,
|
|
1
|
+
{"version":3,"names":["AudioApiError","AudioEventEmitter","FileDirectory","FileFormat","FilePreset","AudioBuffer","withDefaultOptions","inOptions","directory","Cache","subDirectory","fileNamePrefix","channelCount","format","M4A","batchDurationSeconds","preset","High","androidFlushIntervalMs","AudioRecorder","onAudioReadySubscription","onErrorSubscription","options_","isFileOutputEnabled","audioEventEmitter","global","constructor","recorder","createAudioRecorder","enableFileOutput","options","parsedOptions","result","disableFileOutput","start","status","path","fileNameOverride","stop","pause","resume","connect","node","wasConnected","getNode","disconnect","onAudioReady","callback","clearOnAudioReady","remove","addAudioEventListener","event","audioBuffer","buffer","setOnAudioReady","sampleRate","bufferLength","callbackId","subscriptionId","isRecording","isPaused","getCurrentDuration","onError","clearOnError","setOnError"],"sourceRoot":"../../../src","sources":["core/AudioRecorder.ts"],"mappings":";;AAAA,SAASA,aAAa,QAAQ,oBAAW;AACzC,SAASC,iBAAiB,QAAgC,oBAAW;AAMrE,SAIEC,aAAa,EACbC,UAAU,QAGL,aAAU;AACjB,OAAOC,UAAU,MAAM,yBAAsB;AAC7C,OAAOC,WAAW,MAAM,kBAAe;AAGvC;AACA;AACA,SAASC,kBAAkBA,CACzBC,SAAmC,EACC;EACpC,OAAO;IACLC,SAAS,EAAEN,aAAa,CAACO,KAAK;IAC9BC,YAAY,EAAE,UAAU;IACxBC,cAAc,EAAE,WAAW;IAC3BC,YAAY,EAAE,CAAC;IACfC,MAAM,EAAEV,UAAU,CAACW,GAAG;IACtBC,oBAAoB,EAAE,CAAC;IACvBC,MAAM,EAAEZ,UAAU,CAACa,IAAI;IACvBC,sBAAsB,EAAE,GAAG;IAC3B,GAAGX;EACL,CAAC;AACH;AAEA,eAAe,MAAMY,aAAa,CAAC;EACvBC,wBAAwB,GAAkC,IAAI;EAC9DC,mBAAmB,GAAkC,IAAI;EAEzDC,QAAQ,GAAoC,IAAI;EAClDC,mBAAmB,GAAY,KAAK;EAEzBC,iBAAiB,GAAG,IAAIvB,iBAAiB,CAC1DwB,MAAM,CAACxB,iBACT,CAAC;EAEDyB,WAAWA,CAAA,EAAG;IACZ,IAAI,CAACC,QAAQ,GAAG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+1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native-audio-api",
|
|
3
|
-
"version": "0.12.0-nightly-
|
|
3
|
+
"version": "0.12.0-nightly-3254662-20260127",
|
|
4
4
|
"description": "react-native-audio-api provides system for controlling audio in React Native environment compatible with Web Audio API specification",
|
|
5
5
|
"bin": {
|
|
6
6
|
"setup-rn-audio-api-web": "./scripts/setup-rn-audio-api-web.js"
|