@siteed/expo-audio-studio 2.16.0 → 2.16.2
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/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
10
|
|
|
11
|
+
## [2.16.2] - 2025-07-27
|
|
12
|
+
### Changed
|
|
13
|
+
- chore(expo-audio-studio): release @siteed/expo-audio-studio@2.16.1 ([c9614d4](https://github.com/deeeed/expo-audio-stream/commit/c9614d4ebf87d73c3c5b2f7d6e60492fd5e45e64))
|
|
14
|
+
## [2.16.1] - 2025-07-27
|
|
15
|
+
### Changed
|
|
16
|
+
- fix(expo-audio-studio): fix Android audio analysis accumulation showing 0 bytes ([012d478](https://github.com/deeeed/expo-audio-stream/commit/012d478c372db12b9fcf4a49f567d6618eb499f1))
|
|
17
|
+
- chore(expo-audio-studio): release @siteed/expo-audio-studio@2.16.0 ([34c8c0f](https://github.com/deeeed/expo-audio-stream/commit/34c8c0f2f587ecde9adf97c539289b128f0bccc1))
|
|
11
18
|
## [2.16.0] - 2025-07-27
|
|
12
19
|
### Changed
|
|
13
20
|
- feat(expo-audio-studio): optimize stop recording performance for long recording on android ([4553dc9](https://github.com/deeeed/expo-audio-stream/commit/4553dc9d2bd101a461f3f2eadfed63114f7d1b22))
|
|
@@ -357,7 +364,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
357
364
|
- Feature: Audio features extraction during recording.
|
|
358
365
|
- Feature: Consistent WAV PCM recording format across all platforms.
|
|
359
366
|
|
|
360
|
-
[unreleased]: https://github.com/deeeed/expo-audio-stream/compare/@siteed/expo-audio-studio@2.16.
|
|
367
|
+
[unreleased]: https://github.com/deeeed/expo-audio-stream/compare/@siteed/expo-audio-studio@2.16.2...HEAD
|
|
368
|
+
[2.16.2]: https://github.com/deeeed/expo-audio-stream/compare/@siteed/expo-audio-studio@2.16.1...@siteed/expo-audio-studio@2.16.2
|
|
369
|
+
[2.16.1]: https://github.com/deeeed/expo-audio-stream/compare/@siteed/expo-audio-studio@2.16.0...@siteed/expo-audio-studio@2.16.1
|
|
361
370
|
[2.16.0]: https://github.com/deeeed/expo-audio-stream/compare/@siteed/expo-audio-studio@2.15.0...@siteed/expo-audio-studio@2.16.0
|
|
362
371
|
[2.15.0]: https://github.com/deeeed/expo-audio-stream/compare/@siteed/expo-audio-studio@2.14.9...@siteed/expo-audio-studio@2.15.0
|
|
363
372
|
[2.14.9]: https://github.com/deeeed/expo-audio-stream/compare/@siteed/expo-audio-studio@2.14.8...@siteed/expo-audio-studio@2.14.9
|
|
@@ -77,7 +77,7 @@ class AudioRecorderManager(
|
|
|
77
77
|
|
|
78
78
|
private var audioRecord: AudioRecord? = null
|
|
79
79
|
private var bufferSizeInBytes = 0
|
|
80
|
-
private
|
|
80
|
+
private val _isRecording = AtomicBoolean(false)
|
|
81
81
|
private val isPaused = AtomicBoolean(false)
|
|
82
82
|
private var streamUuid: String? = null
|
|
83
83
|
private var audioFile: File? = null
|
|
@@ -378,7 +378,7 @@ class AudioRecorderManager(
|
|
|
378
378
|
return deviceDisconnectionBehavior ?: "pause" // Default to pause if not specified
|
|
379
379
|
}
|
|
380
380
|
|
|
381
|
-
//
|
|
381
|
+
// Public property to check if recording is active
|
|
382
382
|
val isRecording: Boolean
|
|
383
383
|
get() = _isRecording.get()
|
|
384
384
|
|
|
@@ -1403,8 +1403,8 @@ class AudioRecorderManager(
|
|
|
1403
1403
|
|
|
1404
1404
|
// Initialize timing variables
|
|
1405
1405
|
var lastEmitTime = System.currentTimeMillis()
|
|
1406
|
-
|
|
1407
|
-
|
|
1406
|
+
lastEmissionTimeAnalysis = System.currentTimeMillis() // Use the class-level variable
|
|
1407
|
+
isFirstAnalysis = true // Use the class-level variable
|
|
1408
1408
|
var shouldProcessAnalysis = false
|
|
1409
1409
|
|
|
1410
1410
|
// Debug log for intervals
|
|
@@ -1420,7 +1420,7 @@ class AudioRecorderManager(
|
|
|
1420
1420
|
while (_isRecording.get() && !Thread.currentThread().isInterrupted) {
|
|
1421
1421
|
loopCount++
|
|
1422
1422
|
if (loopCount % 100 == 0) {
|
|
1423
|
-
LogUtils.d(CLASS_NAME, "Recording loop iteration $loopCount,
|
|
1423
|
+
LogUtils.d(CLASS_NAME, "Recording loop iteration $loopCount, isRecording: ${_isRecording.get()}")
|
|
1424
1424
|
}
|
|
1425
1425
|
if (isPaused.get()) {
|
|
1426
1426
|
Thread.sleep(100) // Add small delay when paused
|
|
@@ -1456,6 +1456,11 @@ class AudioRecorderManager(
|
|
|
1456
1456
|
totalDataSize += bytesRead
|
|
1457
1457
|
|
|
1458
1458
|
accumulatedAudioData.write(audioData, 0, bytesRead)
|
|
1459
|
+
|
|
1460
|
+
// Also accumulate data for analysis if enabled
|
|
1461
|
+
if (shouldProcessAnalysis) {
|
|
1462
|
+
accumulatedAnalysisData.write(audioData, 0, bytesRead)
|
|
1463
|
+
}
|
|
1459
1464
|
|
|
1460
1465
|
// Handle regular audio data emission
|
|
1461
1466
|
if (currentTime - lastEmitTime >= recordingConfig.interval) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@siteed/expo-audio-studio",
|
|
3
|
-
"version": "2.16.
|
|
3
|
+
"version": "2.16.2",
|
|
4
4
|
"description": "Comprehensive audio processing library for React Native and Expo with recording, analysis, visualization, and streaming capabilities across iOS, Android, and web",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "commonjs",
|