3

I have an audio record that is precious to me, was made years ago, and I got it via an mms type of message on my old GSM phone.

According to ffprobe.exe -show_entries format:stream -count_frames -count_packets -i mms-1.amr > input.txt, the audio has the following specs:

    [STREAM]
    codec_name=amr_nb
    codec_long_name=AMR-NB (Adaptive Multi-Rate NarrowBand)
    codec_time_base=1/8000
    codec_tag_string=samr
    sample_rate=8000
    channels=1
    channel_layout=mono
    bits_per_sample=0
    duration_ts=275840
    duration=34.480000
    bit_rate=6000
    nb_read_frames=1724
    nb_read_packets=1724
    [/STREAM]
    [FORMAT]
    filename=mms-1.amr
    nb_streams=1
    format_long_name=3GPP AMR
    bit_rate=6401
    probe_score=100
    [/FORMAT]

So, I tried several times with ffmpeg but the only workable approach I found was a two leg conversion, extracting the raw audio first:

1)ffmpeg -i mms-1.amr -f s16le -c:a pcm_s16le output.raw

2)ffmpeg -f s16le -ar 8000 -ac 1 -i output.raw mms-1.wav

Interestingly, the original file size is 27KB, the wave file is 539KB!

Two questions:

  1. Is this the only way to convert an .amr type of audio file into any format to be easily recognised by Windows system? What about a single line of code to convert straight into wav format?

  2. Is there /are there/ any good audio filters within ffmpeg to accentuate a voice in the record. The answer to an old question here mentions "equalizing as a proper technique to filter noise out and improve voice recognition..." but I failed so far to find a good explanation of how it works. Any other filters?

USIKPA
  • 51
  • 1
  • 4
  • Just a comment: when trying a one-leg, straight conversion, I get a `wav` file with `adpcm` sound compression, which isn't playable on an average Windows computer – USIKPA Jun 10 '18 at 18:05
  • and what output format you desire to have out of it? coz every format has own rules when comes to size so if your arm is 27KB its impossible to have 27KB mp3 out of it (well its possible but with significant quality loss). I recon you to use portable version of Audacity - https://www.audacityteam.org/ - instead of ffmpeg (it has a lot of filters avail, even voice enhancment) – gamer0 Jun 10 '18 at 19:13
  • Does `ffmpeg -i mms-1.amr -c:a pcm_s16le output.wav` not work? The output is going to be much larger since AMR is a lossy codec, and WAV is not — it stores everything raw, so the benefits of lossy compression go away. – slhck Jun 11 '18 at 09:41

0 Answers0