ffmpeg does not recognize any audio filters

08
2014-07
  • Sudh

    I am trying to reduce noise from the audio files I extracted from videos. The objective is to recognize speech so I was trying to filter out the frequencies above 300 and below 3000hz. I tried to use equalizer filter by issuing command:

    ffmpeg -f lavfi -i "amovie=input.wav,equalizer=f=1300:width_type=h:width=1000" output.wav

    but it gives me error :

    C:\Users\Sudh\Downloads>ffmpeg -f lavfi -i "amovie=input.wav,equalizer=f=300:w
    th_type=h:width=3000" output.wav >output.txt
    ffmpeg version git-2012-03-03-663d727-xuggle-4.0 Copyright (c) 2000-2012 the F
    peg developers
      built on Mar 20 2012 16:24:58 with gcc 4.5.2
      configuration: --prefix=/d/desarrollo/xuggle --extra-version=xuggle-4.0 --ex
    a-cflags=-I/d/desarrollo/xuggle/xuggle_v5/xuggle-xuggler-win/build/native/x86_
    -w64-mingw32/captive/stage/d/desarrollo/xuggle/include --extra-ldflags=-L/d/de
    rrollo/xuggle/xuggle_v5/xuggle-xuggler-win/build/native/x86_64-w64-mingw32/cap
    ve/stage/d/desarrollo/xuggle/lib --enable-shared --enable-gpl --enable-nonfree
    -enable-libx264 --enable-version3 --enable-cross-compile --cross-prefix= --arc
    x86_64 --target-os=mingw32 --enable-libmp3lame --enable-libvorbis --enable-lib
    eora --enable-libspeex --enable-libvo-aacenc --enable-libopencore-amrnb --enab
    -libopencore-amrwb --enable-librtmp --enable-openssl --enable-zlib --enable-li
    px
      libavutil      51. 41.100 / 51. 41.100
      libavcodec     54.  4.100 / 54.  4.100
      libavformat    54.  1.100 / 54.  1.100
      libavdevice    53.  4.100 / 53.  4.100
      libavfilter     2. 62.101 /  2. 62.101
      libswscale      2.  1.100 /  2.  1.100
      libswresample   0.  7.100 /  0.  7.100
      libpostproc    52.  0.100 / 52.  0.100
    [wav @ 00000000006DB360] max_analyze_duration 5000000 reached at 5120000
    [amovie @ 00000000006D9DF0] seek_point:0 format_name:(null) file_name:input.wa
    stream_index:0
    [lavfi @ 00000000006D97F0] No such filter: 'equalizer'
    amovie=input.wav,equalizer=f=300:width_type=h:width=3000: Invalid argument
    

    I tried to use bandreject filter too

    ffmpeg -f lavfi -i "amovie=input.wav,equalizer=f=1300:width_type=h:width=1000" output.wav

    but with the same result saying No such filter bandreject

    What am I missing? ALso please let me know if there is a better way to reduce noise usiong ffmpeg.

    Also I am using latest 64 bit static version from http://ffmpeg.zeranoe.com/builds/

  • Answers
  • Sudh

    I found the solution, which was simply migrating to the new version of ffmpeg from http://ffmpeg.zeranoe.com/builds/ . Also make sure to restart the system and change environment variables to remove traces of older ffmpeg.


  • Related Question

    Can't get ffmpeg to use frei0r on OSX (through homebrew)
  • user861181

    I am trying to get ffmpeg to use frei0r plugin and although I was able to get frei0r show up in filters list, I get the error:

     [frei0r @ 0x10331c1c0] Could not find module 'glow'
     Error initializing filter 'frei0r' with args 'glow:0.5'
    

    I use homebrew. I got ffmpeg to build with --enable-frei0r --enable-filter=frei0r the instruction from this git:

    https://github.com/mxcl/homebrew/commit/f63399c3d0241e7534e73b9fe9d4413b151414b9

    But can't get to actually using the frei0r.

    EDIT: Here is full output:

    $ ffmpeg -i 1.mp4 -vf -vf frei0r=glow:0.5 output.mpg
     ffmpeg version 0.10 Copyright (c) 2000-2012 the FFmpeg developers  built on Mar  4 2012       11:47:02 with clang 3.0 (tags/Apple/clang-211.10.1)
      configuration: --prefix=/usr/local/Cellar/ffmpeg/0.10 --enable-shared --enable-gpl --enable-version3 --enable-nonfree --enable-hardcoded-tables --enable-libfreetype --cc=/usr/bin/clang --enable-libx264 --enable-libfaac --enable-libmp3lame --enable-librtmp --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libxvid --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libass --disable-ffplay --enable-frei0r --enable-filter=frei0r --enable-filter=frei0r_src --enable-libopencv
      libavutil      51. 34.101 / 51. 34.101
      libavcodec     53. 60.100 / 53. 60.100
      libavformat    53. 31.100 / 53. 31.100
      libavdevice    53.  4.100 / 53.  4.100
      libavfilter     2. 60.100 /  2. 60.100
      libswscale      2.  1.100 /  2.  1.100
      libswresample   0.  6.100 /  0.  6.100
      libpostproc    52.  0.100 / 52.  0.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '1.mp4':
      Metadata:
        major_brand     : isom
        minor_version   : 512
        compatible_brands: isomiso2avc1mp41
        creation_time   : 2011-12-15 10:24:56
        encoder         : Lavf53.24.0
      Duration: 00:00:15.44, start: 0.000000, bitrate: 2736 kb/s
        Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1920x1080, 2604 kb/s, 23.98 fps, 23.98 tbr, 48k tbn, 47.95 tbc
        Metadata:
          creation_time   : 2011-12-15 10:24:56
          handler_name    : VideoHandler
        Stream #0:1(und): Audio: aac (mp4a / 0x6134706D), 44100 Hz, stereo, s16, 128 kb/s
        Metadata:
          creation_time   : 2011-12-15 10:24:56
          handler_name    : 
    [NULL @ 0x7fcb9184a400] Unable to find a suitable output format for 'frei0r=glow:0.5'
    frei0r=glow:0.5: Invalid argument
    

  • Related Answers
  • E.G.

    try the following:

    ffmpeg -v debug -i 1.mp4 -vf frei0r=glow:0.5 output.mpg

    and you will probably see something like this:

    [Parsed_frei0r_0 @ 0x7fe7834196a0] Looking for frei0r effect in '/Users/user/.frei0r-1/lib/glow.dylib' [Parsed_frei0r_0 @ 0x7fe7834196a0] Looking for frei0r effect in '/usr/local/lib/frei0r-1/glow.dylib' [Parsed_frei0r_0 @ 0x7fe7834196a0] Looking for frei0r effect in '/usr/lib/frei0r-1/glow.dylib'

    and ffmpeg is probably right. If you will ls -l /usr/local/lib/frei0r-1/ you will see the the plug-in are installed with .so extension.

    On my machine (OSX 10.7.3, ffmpeg 1.0 & frei0r-1.3), I just did something like:

    for file in /usr/local/lib/frei0r-1/*.so ; do cp $file "${file%.*}.dylib" ; done

    which solved the problem, because the .so library had 2 architectures, i386 and x86_64.

    I'm sure it's not a generic solution, but it did the job for me.

  • slhck

    I also had this problem and discovered this environment variable in the ffmpeg vf_frei0r.c source at line 229:

    if ((path = av_strdup(getenv("FREI0R_PATH")))) {
    ...
    

    Consequently, setting this using

    export FREI0R_PATH=/path/to/.so-files
    

    worked for me. Replace this path with wherever your .so files for libfrei0r are stored.