I’m on macOS Catalina 10.15.4, using Audacity 2.4.1.
I installed FFmpeg as per the instructions (64-bit using the pkg). I can export to AC3 and WMA. But when I try to export to M4A (AAC), it gives:
Can’t open audio codec “aac” (0x15002)
I’ve tried with Project Rate of 44.1 kHz and 48 kHz, with a single mono track and a single stereo track, with different quality settings (though mostly with the default). I have tried uninstalling the app and deleting all settings/libraries - i.e.
Deleted ~/Library/Application Support/audacity
Deleted /Library/Application Support/audacity
I then reinstalled Audacity and FFmpeg, but with the same result.
Nothing gets registered in the log file.
The only possible reason I can think of is that I had previous installed audacity using Homebrew. I discovered that isn’t possible any more, so uninstalled it (with brew uninstall). I also had ffmpeg 4.2.2 installed independently through Homebrew, and uninstalled that as well. Still no luck.
Incidentally, the log file gives the following for the FFmpeg library version numbers:
16:09:04: AVCodec version 0x373466 - 55.52.102 (built against 0x373466 - 55.52.102)
16:09:04: AVFormat version 0x372164 - 55.33.100 (built against 0x372164 - 55.33.100)
16:09:04: AVUtil version 0x344264 - 52.66.100 (built against 0x344264 - 52.66.100)
Error 0x15002 > occurs if you export more than a 2-channel M4A file (such as a 5.1 surround sound file), using the “M4A (AAC) Files (FFmpeg)” export choice. To correct the error and export up to 8 channels, choose (external program) and specify a command that tells Audacity to explicitly use the native FFmpeg AAC encoder.
I too am receiving the same error in 2.4.1 when trying to create the M4A file. My setup and workflow is identical to what I had in 2.3.3: Stereo input from a tape deck and output to bluetooth Logitech headphones. No fancy multi channel mixing which is what the FAQ refers to.
I tried the explicit export as per the FAQ as pointed out in the prior msg, but that failed the same way. I reinstalled both Audacity and the FFmpeg code and received the same error.
One of the Audacity developers has been looking into this.
It appears that there has been a problem with the AAC encoder for a long time, but it has been mostly hidden by another bug. That other bug has now been fixed, exposing this bug. This is now logged on the Audacity bug tracker.