WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: chromium-browser missing video support  (Read 6485 times)

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1499
chromium-browser missing video support
« on: October 02, 2019, 11:53:58 PM »
Hopefully you guys are not tired of me yet :-[

I'm using chromium-browser.tcz on Pure64 10.1. The browser works beautifully, except that all videos I try to watch (with notable exception of those on youtube.com) fail. The error shown varies per website, but is usually some variant of "format not supported". Here is a random example from amazon.com: https://tinyurl.com/y3ybf6gh

ffmpeg4.tcz and Xorg-7.7-3d.tcz are loaded. I'm obviously missing extension(s) or setting(s), but am not sure what to try next. Any ideas?

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11594
Re: chromium-browser missing video support
« Reply #1 on: October 03, 2019, 10:24:41 AM »
Hi GNUser
The video plays for me using Firefox ESR 52.1.2. The only "extras" it has is listed under  Plugins  as:
Quote
OpenH264 Video Codec provided by Cisco Systems, Inc. 1.6

This plugin is automatically installed by Mozilla to comply with the WebRTC specification and to enable WebRTC calls with devices that
require the H.264 video codec. Visit http://www.openh264.org/ to view the codec source code and learn more about the implementation.

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1499
Re: chromium-browser missing video support
« Reply #2 on: October 03, 2019, 10:38:21 AM »
I'm trying to stick with chromium because firefox requires both dbus and pulseaudio, which I would rather do without.

chromium can play that video out of the box in Devuan, without any browser plugins or ancillary packages (in Devuan's list of installed packages, the only one with "chromium" in the name is chromium itself). I'm guessing there is something missing from my TC system that is required for video playback within the browser. (I wish I knew how to figure out what chromium is using from the Devuan system when it plays the video...)

CORRECTION: In Devuan I actually have both chromium and iridium installed. Iridium can play the videos, but not chromium. Chromium in Devuan gives the same errors as in TC. Oops. It seems h264 support needs to be enabled at compilation time. See this: https://unix.stackexchange.com/q/285120
« Last Edit: October 03, 2019, 10:59:34 AM by GNUser »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11594
Re: chromium-browser missing video support
« Reply #3 on: October 03, 2019, 10:54:32 AM »
Hi GNUser
I was not suggesting you switch to Firefox. Just pointing out that it had a CODEC pre-installed. Speaking of which, I see the  .info
file for  firefox-ESR.tcz  lists  libavcodec.tcz  as an optional dependency, which is installed on my system.

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1499
Re: chromium-browser missing video support
« Reply #4 on: October 03, 2019, 10:56:58 AM »
Got it. Sorry to have assumed.
Indeed, it seems missing h264 support is the issue. See my correction above--it crossed with your last post. I will dig a bit more.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11594
Re: chromium-browser missing video support
« Reply #5 on: October 03, 2019, 11:19:07 AM »
Hi GNUser
Got it. Sorry to have assumed. ...
No problem. I  "ass u me"  all the time. :)  For what it's worth, there are some compilation notes here:
http://tinycorelinux.net/9.x/x86_64/tcz/src/chromium-browser/

Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14801
Re: chromium-browser missing video support
« Reply #6 on: October 03, 2019, 11:30:55 AM »
If you start chromium-browser from a terminal window, do you get any more error details?

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1499
Re: chromium-browser missing video support
« Reply #7 on: October 03, 2019, 11:42:55 AM »
Yes:
Code: [Select]
[1:15:1003/114223.754644:ERROR:render_media_log.cc(30)] MediaEvent: MEDIA_ERROR_LOG_ENTRY {"error":"FFmpegDemuxer: no supported streams"}
[1:1:1003/114223.755877:ERROR:render_media_log.cc(30)] MediaEvent: PIPELINE_ERROR DEMUXER_ERROR_NO_SUPPORTED_STREAMS

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1499
Re: chromium-browser missing video support
« Reply #8 on: October 03, 2019, 01:06:46 PM »
I figured out a workaround: Use iridium-browser instead. I prefer iridium anyway, as it's more secure by default.
WARNING: What follows is a horrible, horrible hack. I'm just too lazy to do things properly when I'm the only one who'll be using it.

Code: [Select]
1. Download the latest iridium browser:
$ cd $HOME/Downloads
$ wget https://downloads.iridiumbrowser.de/deb/pool/main/i/iridium-browser/iridium-browser_2019.04.73-1iridium0_amd64.deb

2. Extract the contents:
$ tce-load -wi flex bash # flex is needed by ar, bash is needed by iridium-browser itself (shame on them)
$ ar x iridium-browser_2019.04.73-1iridium0_amd64.deb
$ xz -d data.tar.xz
$ tar -xvf data.tar

3. Create a tcz extension from the contents:
$ mkdir root
$ mv ./etc ./root
$ mv ./usr ./root
 # strip everything to make smaller:
$ find . | xargs file | grep "executable" | grep ELF | grep "not stripped" | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || find . | xargs file | grep "shared object" | grep ELF | grep "not stripped" | cut -f 1 -d : | xargs strip -g 2> /dev/null
$ mksquashfs root/ iridium-browser.tcz

4. Put things in your tcedir/optional/ directory:
a. Copy iridium-browser.tcz to tcedir/optional/
b. Grab chromium-browser.tcz.dep from the TC repository, rename it iridium-browser.tcz.dep, add bash.tcz to it, copy it to tcedir/optional/

5. "Convert" your chromium profile:
$ cp $HOME/.config/chromium $HOME/.config/iridium

6. Enjoy!
$ tce-load -i iridium-browser
$ iridium-browser

I'm happy with this workaround until a proper solution comes around. h264 support must be baked-in, since h264 videos play just fine even without ffmpeg4.tcz loaded.
« Last Edit: October 03, 2019, 01:31:12 PM by GNUser »

Offline jazzbiker

  • Hero Member
  • *****
  • Posts: 934
Re: chromium-browser missing video support
« Reply #9 on: October 03, 2019, 03:39:37 PM »
Ohh, nnnnoooo! Upsssss, What? ZZZZapppp,,,, Yea........

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1499
Re: chromium-browser missing video support
« Reply #10 on: October 03, 2019, 08:17:32 PM »
Hmmm... jazzbiker must either really like or really hate my workaround ;)

Offline neonix

  • Wiki Author
  • Sr. Member
  • *****
  • Posts: 391
Re: chromium-browser missing video support
« Reply #11 on: October 04, 2019, 08:49:00 AM »
If you start chromium-browser from a terminal window, do you get any more error details?

I tested chromium-browser.tcz 66.0.3343.0 and it looks like it doesn't play h.264, Theora (VP3) and Webm (VP8) but it plays VP9 + opus (on youtube).  Terminal doesn't display any error when I go to youtube livestream or https://www.quirksmode.org/html5/tests/video.html
but when I open http://techslides.com/demos/sample-videos/small.mp4 I get:

Code: [Select]
[1:15:1004/144047.674512:ERROR:render_media_log.cc(30)] MediaEvent: MEDIA_ERROR_LOG_ENTRY {"error":"FFmpegDemuxer: no supported streams"}
[1:1:1004/144047.678277:ERROR:render_media_log.cc(30)] MediaEvent: PIPELINE_ERROR DEMUXER_ERROR_NO_SUPPORTED_STREAMS

This file also work:
http://techslides.com/demos/sample-videos/small.ogv
I didn't installed any ffmpeg extension.

If you want to determine you browser version go to:
https://www.whatismybrowser.com/