Online video hissing on Raspberry Pi

Users and developers helping users with generic and technical Pale Moon issues on all operating systems.

Moderator: trava90

Forum rules
This board is for technical/general usage questions and troubleshooting for the Pale Moon browser only.
Technical issues and questions not related to the Pale Moon browser should be posted in other boards!
Please keep off-topic and general discussion out of this board, thank you!
Fidelis

Online video hissing on Raspberry Pi

Unread post by Fidelis » 2021-03-08, 08:05

I've been familiar with the PaleMoon browser for quite some time. Lately I've installed it on the Raspberry PI 3B+, as other browsers (Firefox, Chromium, even Epiphany) caused the system to hang. To my greatest surprise, only the PaleMoon showed decent results without hanging the whole system. But the strangest thing is that when watching the online video, the clear sound can be heard only when watching the YouTube. If I try any other online video hosting in Russia (rutube.ru or chetv.ru), I'll hear only hissing instead of sound. I've tried various solutions: installed and updated quite a number of codecs and encoders (ubuntu-restricted-extras and so on), but all turned out in vain. This doesn't happen in Windows 7 (I have another computer with it) or a desktop version of Ubuntu 18.04 amd64 - the sound is crystal clear, everything is round and brown. Instead on the Raspberry Pi 3B+ (I run it with Raspbian 10 and Ubuntu Mate 20.04 - both working with the armhf architecture with PulseAudio, if I'm not mistaken) I can hear only hissing when I watch an online video different from the YouTube. I also tried installing the Firefox for the sake of some inbuilt codecs, but it didn't solve the problem. I tried to compare the tests on the html5test.com, but didn't notice any significant difference between the PaleMoon results on the desktop PC and the Raspberry PI.
What can be the cause of such a bug? Is there a way to watch all kinds of online videos on the PaleMoon, not just YouTube?

User avatar
stevenpusser
Project Contributor
Project Contributor
Posts: 903
Joined: 2015-08-01, 18:33

Re: Online video hissing on Raspberry Pi

Unread post by stevenpusser » 2021-03-10, 22:21

Is the Pale Moon package one of the armhf builds from my OBS repository?

I don't have a Pi myself, but I'll see if anyone on the MX forums with one can reproduce the issue with the MX build.

Pale Moon should be using the system's libavcodec57 or 58 library to power the multimedia playback, and we have backported several versions for the MX repos, so if a certain version of that has the issue, that may make it easier to pin down.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35478
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Online video hissing on Raspberry Pi

Unread post by Moonchild » 2021-03-10, 22:29

Unfortunately there's little our core team can do to help since it seems to be a problem specific to ARM architecture audio. Of course we'll be open to any specific patches if ones are found but there's little we ourselves can do.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

User avatar
stevenpusser
Project Contributor
Project Contributor
Posts: 903
Joined: 2015-08-01, 18:33

Re: Online video hissing on Raspberry Pi

Unread post by stevenpusser » 2021-03-11, 19:27

Here's a link to the MX Linux thread, but not a lot of data yet in it: https://forum.mxlinux.org/viewtopic.php?f=6&t=63591

Jerry just let me know that he went with Pale Moon as the installed browser on the new MX 19 armhf release for the Pi after I suggested he try it out, so that should provide some data. https://mxlinux.org/blog/mx-fluxbox-ras ... now-final/

Fidelis

Re: Online video hissing on Raspberry Pi

Unread post by Fidelis » 2021-03-13, 10:14

In the meantime I tried some primitive workarounds:
- installed the outdated gecko-mediaplayer plugin for Mozilla-like browsers. No result.
- downloaded a fresh build of Ubuntu Mate 20,10 armhf. The result was the same: the YouTube videos had crystal clear sound, other hostings (like rutube.ru) produced hissing.
Maybe I'll try other ways worth speaking about. Hope Jerry will provide some feedback.

New Tobin Paradigm

Re: Online video hissing on Raspberry Pi

Unread post by New Tobin Paradigm » 2021-03-13, 11:19

It could be an issue in ffmpeg or the os audio subsystem.. Since it sometimes works or not sounds more like something to do with ffmpeg codecs.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35478
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Online video hissing on Raspberry Pi

Unread post by Moonchild » 2021-03-13, 11:50

Also, isn't the byte ordering on ARM reversed? that would cause issues with audio if e.g. using 16-bit or float samples.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

Fidelis

Re: Online video hissing on Raspberry Pi

Unread post by Fidelis » 2021-03-13, 19:12

Speaking about ffmpeg.
I found the string "media.ffmpeg.enabled" in the about:config. When I turn it to "false", the YouTube videos continue to show image and sound. instead other video hostings cease to show anything. So it might me the cause of the problem.
As for the general information, i have installed the ffmpeg version 7:4.2.4-1ubuntu0.1. The codec output (ffmpeg -codecs) shows the following^

Code: Select all

ffmpeg version 4.2.4-1ubuntu0.1 Copyright (c) 2000-2020 the FFmpeg developers
  built with gcc 9 (Ubuntu 9.3.0-10ubuntu2)
  configuration: --prefix=/usr --extra-version=1ubuntu0.1 --toolchain=hardened --libdir=/usr/lib/arm-linux-gnueabihf --incdir=/usr/include/arm-linux-gnueabihf --arch=arm --enable-gpl --disable-stripping --enable-avresample --disable-filter=resample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librsvg --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-shared
  WARNING: library configuration mismatch
  avcodec     configuration: --prefix=/usr --extra-version=1ubuntu0.1 --toolchain=hardened --libdir=/usr/lib/arm-linux-gnueabihf --incdir=/usr/include/arm-linux-gnueabihf --arch=arm --enable-gpl --disable-stripping --enable-avresample --disable-filter=resample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librsvg --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-shared --enable-version3 --disable-doc --disable-programs --enable-libaribb24 --enable-liblensfun --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libtesseract --enable-libvo_amrwbenc
  libavutil      56. 31.100 / 56. 31.100
  libavcodec     58. 54.100 / 58. 54.100
  libavformat    58. 29.100 / 58. 29.100
  libavdevice    58.  8.100 / 58.  8.100
  libavfilter     7. 57.100 /  7. 57.100
  libavresample   4.  0.  0 /  4.  0.  0
  libswscale      5.  5.100 /  5.  5.100
  libswresample   3.  5.100 /  3.  5.100
  libpostproc    55.  5.100 / 55.  5.100
I tried to read something about configuring the ffmpeg, found a lot of information about en(de)coding audio and video, but no information about ways to configure the streaming sound. is there any GUI I could use to resolve our issue?

User avatar
trava90
Contributing developer
Contributing developer
Posts: 1736
Joined: 2013-05-20, 18:19
Location: Somewhere in Sector 001

Re: Online video hissing on Raspberry Pi

Unread post by trava90 » 2021-03-15, 12:52

Pale Moon on Linux uses the system-installed FFmpeg (specifically libavcodec) to play MP4 files. Last I knew YouTube defaults to VPx video in most cases instead of MP4 which is likely why you aren't noticing issues there.

Some distros ship their ffmpeg/libavcodec packages stripped of all non-free codecs which can cause issues (I don't know if Ubuntu does this or not). Check your package manager for a "non-free" version of ffmpeg and/or libavcodec.

New Tobin Paradigm

Re: Online video hissing on Raspberry Pi

Unread post by New Tobin Paradigm » 2021-03-15, 13:11

You know, I thought that but never came back to post that.. Then I forgot about it. Thanks for mentioning it Travis.

Fidelis

Re: Online video hissing on Raspberry Pi

Unread post by Fidelis » 2021-03-16, 18:11

I searched the packages manager of the Ubuntu Mate 20.04 armhf, but found only the the usual codecs: libavcodec-extra, libavcodec-extra58 ad libavcodec58. Installing/removing them brings absolutely no effect on the Palemoon. The same packages are in the Debian distro. Can you suggest the "non-free" codecs you mentioned for installation and try?

Fidelis

Re: Online video hissing on Raspberry Pi

Unread post by Fidelis » 2021-03-25, 18:19

I tried to read anything I could find about the "
non-free versions of ffmpeg and/or libavcodec"
and how to make them work with the PaleMoon, but haven't found anything worth mentioning yet. In the meantime I noticed that this issue affects not only the online videos, different from the YouTube, but also online music. I tried to play some tracks on the popular music.yandex.ru service - just to get the same hissing again.
I tried adding the
disable_audio_dither=1
in the config.txt, but it also resulted in vain. Some folks suggest installing another sound card. Maybe that could solve this issue.

User avatar
stevenpusser
Project Contributor
Project Contributor
Posts: 903
Joined: 2015-08-01, 18:33

Re: Online video hissing on Raspberry Pi

Unread post by stevenpusser » 2021-03-29, 23:02

Ubuntu's libavcodecs provide all commonly used streaming video and audio decoders, the same as Debian, so it's not that. :?:

Fidelis

Re: Online video hissing on Raspberry Pi

Unread post by Fidelis » 2021-04-06, 17:44

Today I plugged in an external USB sound blaster. I tested the PaleMoon again on the Raspbian OS and on the Ubuntu 20.04 just to get the same hissing in playing online video different from the YouTube. In the meantime I tried adding the "tsched=0" string to the /etc/pulse/default.pa - to no avail.
Funny enough this problem was reported earlier by the videobloggers, when they tested various distros for the Raspberry Pi. But IMHO the problem is not with the hardware (as soon as both sound blasters produce the same hissing), but somehow has to do with the codecs or the software. It seems rather strange that nobody ever reported it before or thought about any workaround.

New Tobin Paradigm

Re: Online video hissing on Raspberry Pi

Unread post by New Tobin Paradigm » 2021-04-06, 20:15

I agree, it is something with ffmpeg and libav.

User avatar
stevenpusser
Project Contributor
Project Contributor
Posts: 903
Joined: 2015-08-01, 18:33

Re: Online video hissing on Raspberry Pi

Unread post by stevenpusser » 2021-04-08, 19:09

If you can install h.264ify on your machine and Pale Moon, that extension forces Youtube to serve you h.264 video instead of vp9 or whatever you see when you right-click a video there and choose "stats for nerds". That way we can see if changing a video's codec makes any difference--though of course that's just the video codec, but YT may change the audio codec at the same time.

Fidelis

Re: Online video hissing on Raspberry Pi

Unread post by Fidelis » 2021-04-12, 11:44

I would like to give it a try, but the "H264ify" doesn't seem to be installable for the PaleMoon under Linux as an add-on. Are there other options?

User avatar
jobbautista9
Keeps coming back
Keeps coming back
Posts: 782
Joined: 2020-11-03, 06:47
Location: Philippines
Contact:

Re: Online video hissing on Raspberry Pi

Unread post by jobbautista9 » 2021-04-12, 11:50

You can set media.av1.enabled and media.webm.enabled to false in your about:config. Maybe disable media.ffvpx.enabled as well. That should force YouTube to serve you AVC/H264.
Image

merry mimas

XUL add-ons developer. You can find a list of add-ons I manage at http://rw.rs/~job/software.html.

Mima avatar by 絵虎. Pixiv post: https://www.pixiv.net/en/artworks/15431817

Image

Fidelis

Re: Online video hissing on Raspberry Pi

Unread post by Fidelis » 2021-04-17, 17:59

- media.av1.enabled - didn't find the string;
- media.webm.enabled - when turned to false, the sounds turns to hissing on both youTube and other online videos;
- media.ffvpx.enabled - not found as well. I found media.ffmpeg.enabled, but that turns off any kind of online video.
I experimented with other strings, such as:
- media.libavcodec.allow-obsolete - didn't help;
- media.useAudioChannelAPI - the same;
- media.mediasource.webm.audio.enabled - the same.
As I said, I have the PaleMoon on the Ubuntu 20.04 amd64 PC and on Windows 7 (both ordinary laptops), and everything is smooth, but on the same version of Ubuntu running on the armhf architecture (Raspberry Pi 3b+) I have this hissing when playing online video (other from the Youtube). I don't know if it has to do with the CPU architecture.

Locked