A better AAC encoder: FDK-AAC

    • Official Post

    In version 1.2.0 the built-in AAC encoder of FFMpeg seems to be broken. I will look into this, yes.


    But there is an alternative / workaround:


    • Simply extract the libfdk-aac-2.dll file from the attached zip archive to your C:\windows\system32\ directory.


    You will then have the Fraunhofer AAC encoder available in Voukoder. This will work - maybe even better.


    For licensing reasons both needs to be separated.

  • By default FDK-AAC cuts of anything above 17kHz when using CBR mode. It's possible to change it.

    Vouk could you perhaps add button that changes this to 20kHz?


    Workaround for this is to use ("VBR" In Voukoder) Quality Mode 5. Downside to this is that it has lower maximum bitrate.


  • Also discovered:
    FDK-AAC on Voukoder uses wrong format profile according to mediainfo:


    Sampling rate also seems to be wrong.

    • Official Post

    Looked into it:

    1. Default profile in my case is "LC" (Low Complexity)
    2. Bit Rate is 48kbit/s on (auto) but does match to each setting i make
    3. Sampling Rate is 48KHz which looks also good

    Maybe you can reset you parameter cache? I also don't know about your sequence/project settings.


    Trying to find a fix for the noise with AAC now ...


    Edit: When using FFMpeg 4.0 AAC audio is fine. When using 4.1 its distorted. The higher the framerate, the worse.

  • They have some wierd theory behind the delay and apparently it is intentional, even though FFMPEG's standard AAC doesn't do it, neither does Adobe's AAC or any other video-editing suite with AAC support for that matter.


    It isn't an issue with FFMPEG, its by design inside FDK... the delay can be noticed in very highly sychronized fast action video by those who actually create the video... for example my better half says she can't tell the difference.


    But where it really becomes apparent is when you re-import the mp4 with FDKAAC stream into Premiere and you will see the delay in the sample view.


    Unless someone seriously into dissecting code was to fork FDKAAC and engineered their own changes in, I'm afraid it would be wise to just stick with alternative options, for now I just stick with raw 24 bit pcm and let the transcoding server deal with the distribution formats.


    Edit:

    Just want to add for newcomers to AAC... The standard AAC built into FFMPEG is actually BETTER than FDK-AAC at higher than 128kb bitrates. FDKAAC comes into its own below 128k and in part at 128k. But Nero is still the best IMO at all bitrates, but I don't think Vouk will ever add functionality to allow us to use the neroaacencode.exe binary?...

    Edited once, last by Poo2 ().

  • The standard AAC built into FFMPEG is actually BETTER than FDK-AAC at higher than 128kb bitrates. FDKAAC comes into its own below 128k and in part at 128k.

    Do you have more info about this? In all my tests FFMPEGs AAC always sound worse in every bitrate.

  • Simple question, maybe. How can I check if libfdk-aac-2.dll is being picked up or not? I don't see an added option in the audio panel drop down. Using ProcessExplorer it's not attached to the PPro process as a library.

  • Is the use of libfdk-aac-2.dll still recommended for the 2.x versions of Voukoder, or is the quality of the native AAC encoder better now?

  • Thank you for response, I tried to find some more informations about it in the ffmpg wiki, but unfortunately it makes it not quite clear:

    https://trac.ffmpeg.org/wiki/Encode/AAC

    Quote

    The Fraunhofer FDK AAC codec library. This is currently the highest-quality AAC encoder available with ffmpeg.

    and then, later

    Quote

    For AAC-LC: as of 2017 this is no longer necessarily the case. The built in aac encoder is quite good.

    Fo me it sounds like the built in acc encoder makes no difference in AAC-LC, but it still does in main profile. However, I think I have to do some tests of my own, and yes, you're right, lossless is the best but ...not so efficient.

  • I did some tests with a sequence of white noise. I made a screenshot of the spectralview in Audition. The results are attached as PNG-pictures:


    01-uncompreessed.png: Uncompressed - this is what it shoul look like



    02-AAC-ffmpg_CBR_320.png: The native FFMPG AAC Encoder at 320kbit (48Khz stereo) - look at these "glitches"


    03-AAC-ffmpg_CBR_384.png: Same settings but slightly higher bitrate (384kbit) - noticeably better quality


    04-fdkAAC_CBR_320.png: fdk AAC Encoder at 320kbit, very good quality, but frequencies above 17Khz are cut


    05-AAC_x264Pro-plug-in: AAC Encoder of the x264Pro plug-in. I don't know what encoder is used here but it looks outstanding


    So my result is: For best AAC quality in voukoder use the native FFMPG AAC encoder at higher bitrates (min 384) or use the the fdk encoder and live without the 17.000+ frequencies. After some rock concerts these frequencies are blows away, anyway ;) )

    • Official Post

    Workaround for this is to use ("VBR" In Voukoder) Quality Mode 5. Downside to this is that it has lower maximum bitrate.


    I just realized i did not include vbr=5 in the encoder config. I had options vbr=0 to vbr=4 instead of vbr=1 to vbr=5. Fixed that.

  • But i still recommend to use a lossless codec (if possible) if you really want outstanding audio.

    Yes, but in some cases you need to have mp4 file so you have to use AAC audio. It would be nice if you added ability to use Apple CoreAudio AAC. I'm sure its possible to do since OBS does this too (when its installed on system).