The Linux community has long been asking Opera to support the h.264 codec in Opera Browser for Linux.
We know that h.264 is a proprietary format. However, Firefox browser worked around this problem, it uses the codec x264 (free and open-source software library which uses GNU General Public License and it is developed by VideoLAN)
The x264 codec allows browsers to support h.264 codec videos.
For my Opera browser to support h.264, I need to open the terminal and type this command with each new Opera browser update:
curl -L -O https://github.com/iteufel/nwjs-ffmpeg-prebuilt/releases/download/0.39.2/0.39.2-linux-x64.zip
sudo mv libffmpeg.so /usr/lib/x86_64-linux-gnu/libffmpeg_h264.so
sudo mv /usr/lib/x86_64-linux-gnu/opera/libffmpeg.so /usr/lib/x86_64-linux-gnu/opera/libffmpeg.so.orig
sudo ln -s /usr/lib/x86_64-linux-gnu/libffmpeg_h264.so /usr/lib/x86_64-linux-gnu/opera/libffmpeg.so
That's why Opera Browser needs to support the h.264 codec or at least x264 codec (which will not generate license costs for Opera and will once and for all solve this problem that only affects Opera Browser on Linux since Google Chrome and Firefox have been supporting the h.264 codec for a long time, even indirectly via the x264 codec)
I have Lubuntu 18.04.3 LTS (based on Ubuntu 18.04.3 LTS) 64bits and Linux 4.15.0-58 kernel
Thank you for this information! I have Linux Mint LTS 20.0 Cinnamon 64B. I just followed your directions and all videos are now working perfectly including on Twitter.
Earlier I had also installed the following packages, so I just left them and followed your directions.