File tree Expand file tree Collapse file tree 1 file changed +15
-15
lines changed
packages/stream_video/lib/src/call Expand file tree Collapse file tree 1 file changed +15
-15
lines changed Original file line number Diff line number Diff line change @@ -2628,6 +2628,21 @@ class Call {
26282628 return Result .error ('Missing permission to send video' );
26292629 }
26302630
2631+ if (enabled && CurrentPlatform .isAndroid) {
2632+ try {
2633+ if (_streamVideo.options.androidAudioConfiguration != null ) {
2634+ await rtc.Helper .setAndroidAudioConfiguration (
2635+ _streamVideo.options.androidAudioConfiguration! ,
2636+ );
2637+ }
2638+ } catch (e) {
2639+ _logger.w (
2640+ () =>
2641+ '[setMicrophoneEnabled] Failed to set Android audio configuration: $e ' ,
2642+ );
2643+ }
2644+ }
2645+
26312646 final result = await _session? .setMicrophoneEnabled (
26322647 enabled,
26332648 constraints: constraints,
@@ -2640,21 +2655,6 @@ class Call {
26402655 await setAudioInputDevice (_connectOptions.audioInputDevice! );
26412656 }
26422657
2643- if (enabled && CurrentPlatform .isAndroid) {
2644- try {
2645- if (_streamVideo.options.androidAudioConfiguration != null ) {
2646- await rtc.Helper .setAndroidAudioConfiguration (
2647- _streamVideo.options.androidAudioConfiguration! ,
2648- );
2649- }
2650- } catch (e) {
2651- _logger.w (
2652- () =>
2653- '[setMicrophoneEnabled] Failed to set Android audio configuration: $e ' ,
2654- );
2655- }
2656- }
2657-
26582658 _sfuStatsTimers.add (
26592659 Future <void >.delayed (const Duration (seconds: 3 )).then ((_) {
26602660 if (result.getDataOrNull ()! .mediaTrack.enabled) {
You can’t perform that action at this time.
0 commit comments