You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to get speech_to_text to work while Spotify is playing in the background.
Current Behavior
Spotify playing over bluetooth headphones
Start speech_to_text listening
Spotify is ducked (decreases in quality) while speech_to_text listens (this is acceptable)
After speech_to_text is done listening, Spotify stops entirely.
Expected Behavior
4. After speech_to_text is done listening, Spotify continues playing at the original quality.
I'm using the audio_session plugin to try different settings, but none has given me the desired result. Interestingly, if I am not using bluetooth headphones, the expected behavior is realized.
I am trying to get speech_to_text to work while Spotify is playing in the background.
Current Behavior
Expected Behavior
4. After speech_to_text is done listening, Spotify continues playing at the original quality.
I'm using the audio_session plugin to try different settings, but none has given me the desired result. Interestingly, if I am not using bluetooth headphones, the expected behavior is realized.
Current audio_session settings:
await session.configure(AudioSessionConfiguration( avAudioSessionCategory: AVAudioSessionCategory.playAndRecord, avAudioSessionCategoryOptions: AVAudioSessionCategoryOptions.mixWithOthers | AVAudioSessionCategoryOptions.allowBluetooth | AVAudioSessionCategoryOptions.allowBluetoothA2dp, avAudioSessionMode: AVAudioSessionMode.spokenAudio, avAudioSessionRouteSharingPolicy: AVAudioSessionRouteSharingPolicy.defaultPolicy, avAudioSessionSetActiveOptions: AVAudioSessionSetActiveOptions.none, androidAudioAttributes: const AndroidAudioAttributes( contentType: AndroidAudioContentType.speech, flags: AndroidAudioFlags.none, usage: AndroidAudioUsage.voiceCommunication, ), androidAudioFocusGainType: AndroidAudioFocusGainType.gain, androidWillPauseWhenDucked: true, ));
The text was updated successfully, but these errors were encountered: