llfbandit / record

Audio recorder from microphone to a given file path. No external dependencies, MediaRecorder is used for Android an AVAudioRecorder for iOS.
https://pub.dev/packages/record
245 stars 203 forks source link

Cannot record in Wav format on Safari browser #403

Closed elios-cama closed 3 weeks ago

elios-cama commented 2 months ago

Package version record: ^5.1.2

Environment

Describe the bug When i record an audio on an Apple device (iPhone or Mac), with the Wav encoder, the result in the blob is only 44B in size. The data only contains 'RIFF$WAVEfmt D-+data'. The recording process works well and I can fetch the data in bytes on Chrome.

Record configuration : RecordConfig( encoder: AudioEncoder.wav, bitRate: bitRate ?? kBitRate, // here 128000 sampleRate: sampleRate ?? kSampleRate, // here : 44100 ),

To Reproduce Launch a simple record on a flutter web project, and try to read the content from the blob url data.

SidikiSako commented 1 month ago

I have the same problem. Any solution yet ?

AliKarimiENT commented 1 month ago

@elios-cama yes, I have the same issue. I'm recording audio and sending it to the server based on XFile. The file uploads correctly and also the file size is reasonable and ok but no audio while it's working on Chrome