I'm using opera browser version 56.0.3051.43 on Ubuntu 16.04 with I3wm and I get
your browser does not currently recognize any of the video formats available
when trying to play some videos on youtube on respect to HTML5. I've seen a couple forums about this, but only about very outdated versions and none are very clear steps. How can I fix this problem?
Due to legal restrictions Opera is unable to distribute H264 codec. You can use the following workaround:
Install
chromium-codecs-ffmpeg-extra
package and create a link tolibffmpeg.so
:You can check your opera installation directory in the About dialog.
I had installed opera with the
deb
package downloadable from Opera's site and it did not load HTML 5 videos from youtube. The only solution that worked for me was to uninstall the version I had with:and then installed the version from the PPA package following this other AskUbuntu post.
Adding a pointer to the opera stable sources:
Install the key:
Fetch the new repository:
Install latest Opera with:
Now Opera is able to handle HTML5 videos.
From a web search for opera linux enable h.264 I found this answer over on the Unix & Linux SE H.264 support for Opera and openSUSE that suggests trying a few different ideas, but it lead to a more promising looking Opera forum from 4 months ago that might/should work:
Others answers that might be worth trying (from the earlier question) include:
libffmpeg.so
file from https://github.com/iteufel/nwjs-ffmpeg-prebuilt/releases or http://ppa.launchpad.net/saiarcot895/chromium-beta/ubuntu/pool/main/c/chromium-browser/The instructions by Sergey Podobry did not work for me on Ubuntu 19.10. Further digging into the issue, it seems that
chromium-codecs-ffmpeg-extra
does not have the necessary codec anymore. This can be notices if you look at the package list of files here.Instead, this is what I did:
Download the codec from an earlier Ubuntu release, Like 18.04, from here.
Extract the package, and then extract
data.tar.xz
file.Within the extracted folder, navigation to data/usr/lib/chromium-browser. You will find the codec named
libffmpeg.so
.Move this file to
/usr/lib/x86_64-linux-gnu/opera/lib_extra
.Restart Opera.
The problem is not so much with Opera and in all fairness the issue here is with
libffmpeg.so
which is in fact proprietary codec support. I have a little script that adds the support you need after an Opera update or install. Get the script here. Once you have it, make it executable and run it as follows.Hope this helps you out as it has always worked for me. You can then go test your html5 support at https://html5test.com
My FIX: I went to https://www.youtube.com/html5 (Thx Grandpa Dave!),
Everything played fine after that. Pls share if this worked for you. It's a weird auto-location selection. I thought there might be a prob when the comp auto-filled my date/time with another country time, sure enough, youtube matched the incorrect auto location.
If anyone is looking for a one-line Opera install script you can use the following:
I've updated the install script according to Sergey Podobry's answer so it will link the correct video codecs. The script is hosted here.