Audacity and ffmpeg

Questions about applications and software
Forum rules
Before you post please read how to get help

Audacity and ffmpeg

Postby vasmakk on Sun Jun 01, 2014 8:34 am

Hi folks!

Today I tried to load an m4a audio file with Audacity for further editing, but surprisingly the file could not be loaded!
This is the error message I got:
Code: Select all
 "/home/vasmakk/music.m4a" is an Advanced Audio Coding file. Audacity cannot open this type of file. You need to convert it to a supported audio format, such as WAV or AIFF.

This is a codec issue. In earlier versions of LM I had to install ffmpeg and everything worked just fine.
But in LM 17 Qianna ffmpeg is missing! Any suggestions or alternatives?
I want to use Audacity and no other software as I find it very handy...

Thx!
vasmakk
Level 1
Level 1
 
Posts: 32
Joined: Wed May 07, 2014 11:51 am

Linux Mint is funded by ads and donations.
 

Re: Audacity and ffmpeg

Postby kurotsugi on Sun Jun 01, 2014 9:23 am

m4a is using propietary codec, thus audacity will refuse to play it. please run these command and tell us the result
Code: Select all
sudo apt-get update
aptitude search ffmpeg
kurotsugi
Level 6
Level 6
 
Posts: 1037
Joined: Fri Jan 25, 2013 3:54 am

Re: Audacity and ffmpeg

Postby vasmakk on Sun Jun 01, 2014 9:45 am

Thanks kurotsugi for your fast reply!

This is the output

Code: Select all
$ aptitude search ffmpeg
p   chromium-codecs-ffmpeg          - Free ffmpeg codecs for the Chromium Browse
p   chromium-codecs-ffmpeg:i386     - Free ffmpeg codecs for the Chromium Browse
p   chromium-codecs-ffmpeg-dbg      - chromium-codecs-ffmpeg debug symbols     
p   chromium-codecs-ffmpeg-dbg:i386 - chromium-codecs-ffmpeg debug symbols     
p   chromium-codecs-ffmpeg-extra    - Extra ffmpeg codecs for the Chromium Brows
p   chromium-codecs-ffmpeg-extra:i3 - Extra ffmpeg codecs for the Chromium Brows
p   chromium-codecs-ffmpeg-extra-db - chromium-codecs-ffmpeg-extra debug symbols
p   chromium-codecs-ffmpeg-extra-db - chromium-codecs-ffmpeg-extra debug symbols
p   cmus-plugin-ffmpeg              - lightweight ncurses audio player (FFmpeg p
p   cmus-plugin-ffmpeg:i386         - lightweight ncurses audio player (FFmpeg p
p   ffmpeg2theora                   - Theora video encoder using ffmpeg         
p   ffmpeg2theora:i386              - Theora video encoder using ffmpeg         
p   ffmpegthumbnailer               - fast and lightweight video thumbnailer   
p   ffmpegthumbnailer:i386          - fast and lightweight video thumbnailer   
p   ffmpegthumbnailer-dbg           - debugging informations for ffmpegthumbnail
p   ffmpegthumbnailer-dbg:i386      - debugging informations for ffmpegthumbnail
p   ffmpegthumbs                    - video thumbnail generator using ffmpeg   
p   ffmpegthumbs:i386               - video thumbnail generator using ffmpeg   
p   gmerlin-encoders-ffmpeg         - ffmpeg encoders for Gmerlin               
p   gmerlin-encoders-ffmpeg:i386    - ffmpeg encoders for Gmerlin               
i   gstreamer0.10-ffmpeg            - FFmpeg plugin for GStreamer               
p   gstreamer0.10-ffmpeg:i386       - FFmpeg plugin for GStreamer               
p   kffmpegthumbnailer              - video thumbnailer for KDE                 
p   kffmpegthumbnailer:i386         - video thumbnailer for KDE                 
p   libffmpegthumbnailer-dev        - development files for ffmpegthumbnailer   
p   libffmpegthumbnailer-dev:i386   - development files for ffmpegthumbnailer   
p   libffmpegthumbnailer4           - shared library for ffmpegthumbnailer     
p   libffmpegthumbnailer4:i386      - shared library for ffmpegthumbnailer     
p   libxine1-ffmpeg                 - MPEG-related plugins for libxine1         
p   libxine1-ffmpeg:i386            - MPEG-related plugins for libxine1         
p   libxine2-ffmpeg                 - MPEG-related plugins for libxine2         
p   libxine2-ffmpeg:i386            - MPEG-related plugins for libxine2         
p   moc-ffmpeg-plugin               - ncurses based console audio player - ffmpe
p   moc-ffmpeg-plugin:i386          - ncurses based console audio player - ffmpe
p   nepomuk-core-ffmpegextractor    - Nepomuk Semantik Desktop core libraries --
p   nepomuk-core-ffmpegextractor:i3 - Nepomuk Semantik Desktop core libraries --
$


I guess there must be something to install from those packages.
But which one ?
vasmakk
Level 1
Level 1
 
Posts: 32
Joined: Wed May 07, 2014 11:51 am

Re: Audacity and ffmpeg

Postby Flemur on Sun Jun 01, 2014 9:53 am

ffmpeg in synaptic says*:
"This package contains the deprecated ffmpeg program. This package also serves
as a transitional package to libav-tools. Users are advised to use avconv from
the libav-tools package instead of ffmpeg."

I can read (most?) mp4 files with audacity; try installing libav-tools and libavcodec-extra-53.

*Edit: in Mint 16.
Mint 17/Xfce/fluxbox/jackd no pulseaudio
User avatar
Flemur
Level 6
Level 6
 
Posts: 1048
Joined: Mon Aug 20, 2012 9:41 pm

Re: Audacity and ffmpeg

Postby vasmakk on Sun Jun 01, 2014 10:07 am

Flemur wrote:I can read (most?) mp4 files with audacity; try installing libav-tools and libavcodec-extra-53.

*Edit: in Mint 16.


That is the problem Flemur...

There is no libavcodec-extra-53 in Mint 17.
Only libavcodec-extra-54. An this one doesnt support m4a (I have allready installed it!)
Thanks anyway!
vasmakk
Level 1
Level 1
 
Posts: 32
Joined: Wed May 07, 2014 11:51 am

Re: Audacity and ffmpeg

Postby kurotsugi on Sun Jun 01, 2014 10:20 am

m4a and mp4 is two different things but you can try with flemur's suggestion. there are also several alternative tools which can be used to conver m4a file to mp3 such as
- soundconverter
- ffmulticonverter
kurotsugi
Level 6
Level 6
 
Posts: 1037
Joined: Fri Jan 25, 2013 3:54 am

Re: Audacity and ffmpeg

Postby vasmakk on Sun Jun 01, 2014 11:42 am

kurotsugi

Like I said, there is no libavcodec-extra-53 in LM 17 Qiana. Only in previous versions of LM
So I cannot try Flemur's suggestion...
I have already installed libavcodec-extra-54 but that doesnt help!
I am interested to convert m4a files not mp4... I tried other converters, but since most of them use the same codecs (which are not present)
they also dont work... I also tried avconv (from libav-tools) but the same happened. It failed!

Anyway thanks for all your efforts guys
I really don't know what to do! should I install LM 16 again ?
vasmakk
Level 1
Level 1
 
Posts: 32
Joined: Wed May 07, 2014 11:51 am

Re: Audacity and ffmpeg

Postby snipertyler on Sun Jun 01, 2014 12:19 pm

ffmpeg & avconv have been in a bit of a war with some.. deceptive messages from Ubuntu, you may be using the "fake" ffmpeg [1]
So my suggestion would be to get one from their site [2] or compile it yourself [3].
About m4a, it seems that aac is essentially m4a [4] so the binaries from [3] should work fine as they support aac
To "install" swap out the binary you download to where the current one resides (marking it ffmpeg.bak if you're cautious)
You can use whereis ffmpeg or type ffmpeg to find the location.

If audacity doesn't support it after this, ffmpeg will. (not sure how much audacity uses ffmpeg as a backend)
Run ffmpeg by itself and check for a "aac" in the output to make sure it has support.

[1] http://stackoverflow.com/a/9477756/1109017
[2] http://ffmpeg.org/download.html
[3] http://trac.ffmpeg.org/wiki/CompilationGuide
[4] http://www.differencebetween.net/techno ... c-and-m4a/
snipertyler
Level 1
Level 1
 
Posts: 25
Joined: Mon Aug 19, 2013 10:44 am

Re: Audacity and ffmpeg

Postby kurotsugi on Sun Jun 01, 2014 10:22 pm

Code: Select all
avconv -i <filename>.m4a <filename>mp3

this command works perfectly on my system. the aac codec is on libavcodec-extra package. if you have it installed then you should play and convert those file easily.
kurotsugi
Level 6
Level 6
 
Posts: 1037
Joined: Fri Jan 25, 2013 3:54 am

Re: Audacity and ffmpeg

Postby vasmakk on Tue Jun 03, 2014 2:33 am

Thanks kurotsugi
Thank you guys!

Of course all the above solutions work for me too...
But I was hopping to import m4a files directly into Audacity like I used to in LM 13 "Maya".
Now I have to convert them to mp3 wav of aiff formats first, using avconv. And then import them to Audacity
vasmakk
Level 1
Level 1
 
Posts: 32
Joined: Wed May 07, 2014 11:51 am

Re: Audacity and ffmpeg

Postby kurotsugi on Tue Jun 03, 2014 5:10 am

that's a tricky one :3
AFAIK you'll need to compile audacity with libav/ffmpeg integration option turned on. recent audacity didn't have this option turned on by default.
kurotsugi
Level 6
Level 6
 
Posts: 1037
Joined: Fri Jan 25, 2013 3:54 am

Re: Audacity and ffmpeg

Postby vasmakk on Tue Jun 03, 2014 6:42 am

Ok, now I see...
Thx kuro :) for everything
vasmakk
Level 1
Level 1
 
Posts: 32
Joined: Wed May 07, 2014 11:51 am

Re: Audacity and ffmpeg

Postby Ginsu543 on Thu Jun 05, 2014 6:44 pm

kurotsugi wrote:that's a tricky one :3
AFAIK you'll need to compile audacity with libav/ffmpeg integration option turned on. recent audacity didn't have this option turned on by default.

I just found a solution to this, if you're willing to add an unofficial ppa by Doug McMahon (you can check out his Launchpad webpage here). He has recompiled Audacity 2.0.5 with the ffmpeg option turned on and has included the necessary library files in his ppa.

Just follow his instructions:

    1. Open Software Sources and add his ppa (ppa:mc3man/testing5)
    2. Open Synaptic Package
    3. Upgrade Audacity
    4. Install the following three libraries: libavcodec53, libavformat53, and libavutil51
    5. Open Audacity --> Edit --> Preferences --> Libraries and point the FFmpeg Library to /opt/ffmpeg-compat/lib/libavformat.so.53
I used this new-and-improved Audacity to encode a .wav file into .m4a earlier today. Works like a charm!
Main: Intel Core i7 920 D0 @ 4.0 GHz | Asus P6X58D Premium | 12 GB Mushkin Redline PC3-12800 7-8-7-24 | EVGA GeForce GTX 560 Ti | Mint 17 Cinnamon 64 / OS X 10.7.3
Portables: Toshiba Portege R200 | Mint 17 Cinnamon 32 / Dell Mini 9 | OS X 10.6.7
User avatar
Ginsu543
Level 4
Level 4
 
Posts: 392
Joined: Thu Nov 24, 2011 3:15 am
Location: Los Angeles, CA, USA

Linux Mint is funded by ads and donations.
 

Return to Software & Applications

Who is online

Users browsing this forum: Google [Bot] and 13 guests