Fix[output]: low audio volume after fixing microphone

This commit is contained in:
khanhduytran0 committed 2024-07-18 15:41:51 +07:00
1 parent 84c63b5576
commit fcc7efe6d5
1 file changed
+4 -2
+4 -2
View File
@@ -302,8 +302,10 @@ static GameSurfaceView* pojavWindow;
} else {
options = AVAudioSessionCategoryOptionMixWithOthers;
}
[AVAudioSession.sharedInstance setCategory:category withOptions:options error:&sessionError];
[AVAudioSession.sharedInstance setActive:YES error:&sessionError];
AVAudioSession *session = AVAudioSession.sharedInstance;
[session setCategory:category withOptions:options error:&sessionError];
[session setCategory:AVAudioSessionCategoryPlayAndRecord withOptions:AVAudioSessionCategoryOptionDefaultToSpeaker error: nil];
[session setActive:YES error:&sessionError];
}
- (void)updateJetsamControl {