Last active
January 1, 2022 17:44
-
-
Save flaki/2e3a0f1d59ebc723fba57c9053f06765 to your computer and use it in GitHub Desktop.
Console fix for mono audio in stereo videos on YouTube like this one https://youtu.be/P3X3J-8ICAo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(){ | |
vid=document.querySelector('video.html5-main-video'); | |
ct = new AudioContext(); | |
src = ct.createMediaElementSource(vid); | |
splitter = ct.createChannelSplitter(2); | |
src.connect(splitter); | |
merger = ct.createChannelMerger(2); | |
splitter.connect(merger, 0, 0); | |
splitter.connect(merger, 0, 1); | |
merger.connect(ct.destination); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
link didn't work for me, so here is the long version of the sample link
https://www.youtube.com/watch?v=P3X3J-8ICAo