VP9 not working with VLC

2 replies [Last post]
peromax
Offline
Joined: 06/06/2015

When I try to play webm vp9 video downloaded through youtube-dl with VLC I get the following error:
No suitable decoder module:
VLC does not support the audio or video format "VP90". Unfortunately there is no way for you to fix this.

The video is working when I play it with default video player.
I tried with both compiled latest version of VLC as well with repository version.

I am using Trisquel 7.

jxself
Offline
Joined: 09/13/2010

Trisquel does not have built-in support for VP9. I expect that won't happen until Trisquel 8, in 2016. Compiling support yourself will likely also need updated libraries too.

Rather than messing with the host system's libraries you can compile a simple video player called FFplay (from the FFmpeg project) in a chroot like so:

apt-get install debootstrap
mkdir ffmpeg-chroot
sudo debootstrap --arch amd64 belenos ffmpeg-chroot http://us.archive.trisquel.info/trisquel/
sudo chroot ffmpeg-chroot
echo "deb-src http://us.archive.trisquel.info/trisquel/ belenos main" >> /etc/apt/sources.list
echo "deb http://us.archive.trisquel.info/trisquel/ belenos-security main" >> /etc/apt/sources.list
echo "deb-src http://us.archive.trisquel.info/trisquel/ belenos-security main" >> /etc/apt/sources.list
echo "deb http://us.archive.trisquel.info/trisquel/ belenos-updates main" >> /etc/apt/sources.list
echo "deb-src http://us.archive.trisquel.info/trisquel/ belenos-updates main" >> /etc/apt/sources.list
apt-get update
apt-get install language-pack-en-base
# Replace English above with your desired language, if it's not English
apt-get full-upgrade
apt-get install build-essential wget subversion

# Get libogg
wget http://downloads.xiph.org/releases/ogg/libogg-1.3.2.tar.xz
tar xf libogg-1.3.2.tar.xz
cd libogg-1.3.2
./configure --disable-shared
make
make install
cd ../
rm -fr libogg-1.3.2*

# Get libvorbis
wget http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.5.tar.xz
tar xf libvorbis-1.3.5.tar.xz
cd libvorbis-1.3.5
./configure --disable-shared
make
make install
cd ../
rm -fr libvorbis-1.3.5*

# Get Opus
wget http://downloads.xiph.org/releases/opus/opus-1.1.tar.gz
tar xf opus-1.1.tar.gz
cd opus-1.1
./configure --disable-shared
make
make install
cd ../
rm -fr opus-1.1*

# Get libtheora
apt-get install automake libtool
svn co http://svn.xiph.org/trunk/theora
cd theora
./autogen.sh --disable-shared
make
make install
cd ../
rm -fr theora

# Get libvpx
apt-get install yasm git
git clone http://git.chromium.org/webm/libvpx.git
cd libvpx
git checkout v1.4.0
./configure --enable-vp8 --enable-vp9 --enable-postproc --enable-vp9-postproc --disable-examples
make
make install
cd ../
rm -fr libvpx

# Get libx264
git clone git://git.videolan.org/x264.git
cd x264
./configure --enable-static --disable-shared --disable-opencl --disable-avs --disable-cli --disable-ffms --disable-gpac --disable-lavf --disable-swscale --disable-asm
make
make install
ldconfig
cd ../
rm -fr x264

# Get FFmpeg
apt-get -y install pkg-config libsdl1.2-dev
wget http://ffmpeg.org/releases/ffmpeg-2.6.3.tar.gz
tar xf ffmpeg-2.6.3.tar.gz
cd ffmpeg-2.6.3
export LD_LIBRARY_PATH=/usr/local/lib
./configure --enable-gpl --enable-version3 --enable-postproc --enable-libvorbis --enable-libvpx --enable-libopus --enable-pthreads --disable-shared --disable-ffserver --disable-ffprobe --enable-libtheora --enable-libvpx
make

You'll then have a binary called ffplay that you can move to wherever you like and run with:

ffplay /path/to/file

A basic way to play VP9 and Opus without messing with the host system's libraries.

peromax
Offline
Joined: 06/06/2015

Thanks for your reply, I found the solution. First I did apt-get build-dep vlc. Then I installed libvpx-dev and compiled it from latest source and that's it.