Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No sound on certain sites #2

Open
rajun50 opened this issue Mar 15, 2021 · 5 comments
Open

No sound on certain sites #2

rajun50 opened this issue Mar 15, 2021 · 5 comments

Comments

@rajun50
Copy link

rajun50 commented Mar 15, 2021

Some sites audio does not play when this extension is used. Desktop version of Tiktok, for example. Some Reddit videos are also affected.

@vatara
Copy link
Owner

vatara commented Mar 15, 2021

Unfortunately this is a bug/design decision of Firefox:
https://stackoverflow.com/questions/27429123/html5-audio-web-audio-api-cors-and-firefox

Any media with a cross-origin source gets silenced when a script tries to modify it. Unless Firefox changes that the only workaround is to disable compression on those sites.

@rajun50
Copy link
Author

rajun50 commented Mar 15, 2021

Unfortunately this is a bug/design decision of Firefox:
https://stackoverflow.com/questions/27429123/html5-audio-web-audio-api-cors-and-firefox

Any media with a cross-origin source gets silenced when a script tries to modify it. Unless Firefox changes that the only workaround is to disable compression on those sites.

Apologies for my failure to mention it, but this issue is happening on Chrome, not Firefox.

@vatara
Copy link
Owner

vatara commented Mar 15, 2021

Ah, well unfortunately it's the same issue in Chrome too:
https://stackoverflow.com/questions/31083704/mediaelementaudiosource-outputs-zeroes-due-to-cors-access-restrictions

Setting crossOrigin to anonymous from the script doesn't help in Firefox or Chrome. I don't think there's anything I can do. :(

@3941
Copy link

3941 commented Mar 1, 2023

Another extension on the Chrome store, called Audio Channel, does make those sites work.
It exclusively attaches to one tab, though, until you attach it to another one. It can never work on multiple tabs simultaneously.

EDIT: Wait, my bad. It definitely USED to be on the Chrome store, but apparently it was removed. Now I can only find it on the Edge store, here https://microsoftedge.microsoft.com/addons/detail/audio-channel/ebeinfhoghkmbgabidbabfhjikapoama
Now I wonder if Chrome dropped some functionality along the way. Edge supports Chrome extensions, though, so I figure they must be essentially the same.

Maybe you can check it out and implement an optional "exclusive" mode. Because I do like your extension better for not having to manually manage it. The different profiles for websites are really useful. Just the fact it fails on quite a few sites is disappointing. Maybe I'll just use both. Yours for most sites, and Audio Channel whenever I have to.

EDIT2: Gets even weirder. This here USED to be audio channel. The reviews tell as much, and the icon of the extension is still the same.. Wild...
https://chrome.google.com/webstore/detail/iq-tab-custom-new-tab/hafdgamhnmiioimpcdhhbhgcjndgmphd

@vatara
Copy link
Owner

vatara commented Mar 1, 2023

@3941 That's really interesting. I looked through that extensions code a bit and I think it works by using this tabCapture API.

There's some discussion of it on StackOverflow: 1 and 2.

Apparently that is not supported by Firefox: https://bugzilla.mozilla.org/show_bug.cgi?id=1391223

I'm not why it's not in the Chrome store any more, maybe it's related to Manifest V3 changes. It seems like the technique they are using requires the user to interact with the plugin before it activates.

I'm far from an expert, but it seems like extensions are in a weird place right now with browsers pushing to move to Manifest V3 without agreement on what exactly that is. I'll definitely keep this in mind though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants