chore: Downgrade record
This commit is contained in:
parent
0dbaf09cc7
commit
fd22b4330e
5 changed files with 22 additions and 35 deletions
|
|
@ -621,7 +621,7 @@ class ChatController extends State<ChatPageWithRoom> {
|
|||
}
|
||||
}
|
||||
|
||||
if (await AudioRecorder().hasPermission() == false) return;
|
||||
if (await Record().hasPermission() == false) return;
|
||||
final result = await showDialog<RecordingResult>(
|
||||
context: context,
|
||||
barrierDismissible: false,
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ class RecordingDialogState extends State<RecordingDialog> {
|
|||
|
||||
bool error = false;
|
||||
String? _recordedPath;
|
||||
final _audioRecorder = AudioRecorder();
|
||||
final _audioRecorder = Record();
|
||||
final List<double> amplitudeTimeline = [];
|
||||
|
||||
static const int bitRate = 16000;
|
||||
|
|
@ -47,12 +47,7 @@ class RecordingDialogState extends State<RecordingDialog> {
|
|||
await WakelockPlus.enable();
|
||||
|
||||
await _audioRecorder.start(
|
||||
const RecordConfig(
|
||||
autoGain: true,
|
||||
noiseSuppress: true,
|
||||
echoCancel: true,
|
||||
bitRate: bitRate,
|
||||
),
|
||||
bitRate: bitRate,
|
||||
path: path,
|
||||
);
|
||||
setState(() => _duration = Duration.zero);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue