From 36e21e6283070f5e963730f1c96ebe36515e0e70 Mon Sep 17 00:00:00 2001 From: Atsushi Eno Date: Wed, 8 May 2024 16:36:02 +0900 Subject: [PATCH] [manager] issue #199: fix the glitchy outputt issue caused by oboe buffer size. This seems to fix the biggest audio glitch issues generally seen on androidaudioplugin-manager app. It does not fix the issue that reopening the stream results in non-exclusive mode yet. --- .../org/androidaudioplugin/ui/compose/app/PluginManagerScope.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/androidaudioplugin-ui-compose-app/src/main/java/org/androidaudioplugin/ui/compose/app/PluginManagerScope.kt b/androidaudioplugin-ui-compose-app/src/main/java/org/androidaudioplugin/ui/compose/app/PluginManagerScope.kt index 0f01a513..70d198fd 100644 --- a/androidaudioplugin-ui-compose-app/src/main/java/org/androidaudioplugin/ui/compose/app/PluginManagerScope.kt +++ b/androidaudioplugin-ui-compose-app/src/main/java/org/androidaudioplugin/ui/compose/app/PluginManagerScope.kt @@ -56,7 +56,7 @@ class PluginDetailsScope private constructor(val pluginInfo: PluginInformation, val sampleRate = audioManager.getProperty(AudioManager.PROPERTY_OUTPUT_SAMPLE_RATE).toInt() // It is for the audio processor's callback // FIXME: make them configurable? - val frames = 1024 //audioManager.getProperty(AudioManager.PROPERTY_OUTPUT_FRAMES_PER_BUFFER).toInt() + val frames = audioManager.getProperty(AudioManager.PROPERTY_OUTPUT_FRAMES_PER_BUFFER).toInt() val channelCount = 2 PluginPlayer.create(sampleRate, frames, channelCount).apply { setPlugin(instance!!)