


You can then test the file created with ffplay man.opus When converting files with ffmpeg after compilation, you must specify -acodec libopus or ffmpeg will not use the opus codec: ffmpeg -i pc.wav -ar 48000 -ac 2 -acodec libopus -ab 256k man.opus The documentation installed with libopus and ffmpeg will reveal all the options that can be used to convert files. You can then use it to convert files (first to wav) and then to. I know that ffmpeg is deprecated in Ubuntu in favour of Libav, but compiling is a good way to get a fully functioning opus encoder/decoder integrated into ffmpeg itself. On 12.04 (Precise), however, there are dependency problems with installing the opus codecs and tools, so I have found by far the best solution is the one that has become available very recently: compile the opus audio encoder and decoder as noted here, and build ffmpeg with opus support by adding -enable-opus to the configure options of ffmpeg (as listed on the compilation guide). With the package mediainfo installed: $ mediainfo linuxactionshowep309-432p-audio-only.opusĬomplete name : linuxactionshowep309-432p-audio-only.opus Video:0kB audio:53875kB global headers:0kB muxing overhead 0.900602% Output #0, ogg, to 'linuxactionshowep309-432p-audio-only.opus': Encode it with libopus at 100 kbit/s with variable bitrate on: $ avconv -stats -i linuxactionshowep309-432p.mp4 -map 0:1 -c libopus -b 100k linuxactionshowep309-432p-audio-only.opus Take the second stream of the first input ( -map 0:1), which is the audio stream. Expected packet loss percentageĮxample 2: Grab the audio from a video file and encode it as opus Favor improved speech intelligibilityĪudio E.A.
#Opus to m4a converter full
Here are all options for libopus: $ avconv -h full | grep opus -A 11Īvconv version 9.11-6:9.11-3+b2, Copyright (c) 2000-2013 the Libav developersīuilt on 17:45:45 with gcc 4.8 (Debian 4.8.2-16)

Ubuntu 14.04 and Debian 8 ship with version 9 of libav-tools in their repositories, and it has built-in support for Opus through the package libopus0.
