From 0871849de8951526a6f460e0ca54ce49758e6eb3 Mon Sep 17 00:00:00 2001 From: Gerzon Z Date: Tue, 21 Sep 2021 10:47:00 -0400 Subject: [PATCH] [IMPROVE] Voice messages improvements (#3385) Co-authored-by: Diego Mello Co-authored-by: Marco Jacotec --- app/containers/MessageBox/RecordAudio.tsx | 8 ++++---- app/containers/message/Audio.tsx | 2 +- ios/RocketChatRN/Info.plist | 1 + 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/app/containers/MessageBox/RecordAudio.tsx b/app/containers/MessageBox/RecordAudio.tsx index af2bcd832..cec55761f 100644 --- a/app/containers/MessageBox/RecordAudio.tsx +++ b/app/containers/MessageBox/RecordAudio.tsx @@ -17,11 +17,11 @@ interface IMessageBoxRecordAudioProps { onFinish: Function; } -const RECORDING_EXTENSION = '.aac'; +const RECORDING_EXTENSION = '.m4a'; const RECORDING_SETTINGS = { android: { extension: RECORDING_EXTENSION, - outputFormat: Audio.RECORDING_OPTION_ANDROID_OUTPUT_FORMAT_AAC_ADTS, + outputFormat: Audio.RECORDING_OPTION_ANDROID_OUTPUT_FORMAT_MPEG_4, audioEncoder: Audio.RECORDING_OPTION_ANDROID_AUDIO_ENCODER_AAC, sampleRate: Audio.RECORDING_OPTIONS_PRESET_LOW_QUALITY.android.sampleRate, numberOfChannels: Audio.RECORDING_OPTIONS_PRESET_LOW_QUALITY.android.numberOfChannels, @@ -39,7 +39,7 @@ const RECORDING_SETTINGS = { const RECORDING_MODE = { allowsRecordingIOS: true, playsInSilentModeIOS: true, - staysActiveInBackground: false, + staysActiveInBackground: true, shouldDuckAndroid: true, playThroughEarpieceAndroid: false, interruptionModeIOS: Audio.INTERRUPTION_MODE_IOS_DO_NOT_MIX, @@ -147,7 +147,7 @@ export default class RecordAudio extends React.PureComponent UIBackgroundModes + audio fetch voip