AdvancedProfanityFilter
AdvancedProfanityFilter copied to clipboard
Add tv.youtube.com?
The Site
tv.youtube.com
Subtitle Element Node
The text below is captioned: 'I'LL TELL YOU WHY BECAUSE THEY' (then new line) 'ARE TOO BUSY P'.
<div class="caption-window ytp-caption-window-top" id="caption-window-_1228" dir="ltr" tabindex="0" aria-live="assertive" draggable="true" style="touch-action: none; text-align: left; top: 58.2848%; left: 4.4%;" data-layer="4"><span class="captions-text" style="overflow-wrap: normal; display: block;"><span class="caption-visual-line" style="display: block;"><span class="ytp-caption-segment" style="display: inline-block; white-space: pre-wrap; background: rgba(8, 8, 8, 0.75); -webkit-box-decoration-break: clone; border-radius: 2.26111px; font-size: 18.0889px; color: rgb(255, 255, 255); fill: rgb(255, 255, 255); font-family: "YouTube Noto", Roboto, "Arial Unicode Ms", Arial, Helvetica, Verdana, "PT Sans Caption", sans-serif;">I'LL TELL YOU WHY BECAUSE THEY</span></span><span class="caption-visual-line" style="display: block;"><span class="ytp-caption-segment" style="display: inline-block; white-space: pre-wrap; background: rgba(8, 8, 8, 0.75); -webkit-box-decoration-break: clone; border-radius: 2.26111px; font-size: 18.0889px; color: rgb(255, 255, 255); fill: rgb(255, 255, 255); font-family: "YouTube Noto", Roboto, "Arial Unicode Ms", Arial, Helvetica, Verdana, "PT Sans Caption", sans-serif;">ARE TOO BUSY P</span></span></span></div>
Sorry, I've just been really busy lately. I will try to take a look at this soon!
This has now been added to version 2.7.0 Please give it a try and report back how it works. Thanks!
2.7.0 has been submitted to all the browser stores, but each must be approved before it is available. Firefox has already been approved.
Will do!
On Sat, May 16, 2020, 18:06 Richard Frost [email protected] wrote:
This has now been added to version 2.7.0 https://github.com/richardfrost/AdvancedProfanityFilter/releases/tag/2.7.0 Please give it a try and report back how it works. Thanks!
2.7.0 has been submitted to all the browser stores, but each must be approved before it is available. Firefox has already been approved.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/richardfrost/AdvancedProfanityFilter/issues/207#issuecomment-629712063, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACAUZHRLHOIMBLUDV42L6DTRR4E7HANCNFSM4MRP4HSQ .
I was able to test it today. It almost works:
- If I set tv.youtube.com CC to English-DTVCC1 instead of the default CC1 then it captures.
- When catching it is off by about 1 second, so the word is said and then the tab is muted on a following word.
I just verified that caption element with CC1 enabled looks as follows (it looks the same as the previous element best I can tell):
<div class="caption-window ytp-caption-window-bottom ytp-caption-window-rollup" id="caption-window-1" dir="ltr" tabindex="0" aria-live="assertive" lang="en" draggable="true" data-layer="4" style="touch-action: none; text-align: left; overflow: hidden; left: 50%; width: 596px; height: 66px; margin-left: -298px; bottom: 2%;"><span class="captions-text" style="overflow-wrap: normal; display: block;"><span class="caption-visual-line" style="display: block;"><span class="ytp-caption-segment" style="display: inline-block; white-space: pre-wrap; background: rgba(8, 8, 8, 0.75); font-size: 28.4px; color: rgb(255, 255, 255); fill: rgb(255, 255, 255); font-family: "YouTube Noto", Roboto, "Arial Unicode Ms", Arial, Helvetica, Verdana, "PT Sans Caption", sans-serif;">OUT TO BE A REAL JERK.</span></span><span class="caption-visual-line" style="display: block;"><span class="ytp-caption-segment" style="display: inline-block; white-space: pre-wrap; background: rgba(8, 8, 8, 0.75); font-size: 28.4px; color: rgb(255, 255, 255); fill: rgb(255, 255, 255); font-family: "YouTube Noto", Roboto, "Arial Unicode Ms", Arial, Helvetica, Verdana, "PT Sans Caption", sans-serif;">THEY ARE ALL ALIKE!</span></span></span></div>
Here is what the element looks like for DTVCC1 option (I think the element is mostly the same). The word "BUTT" below is a replacement word for A** in caption and was caught by the extension but off by a few words or so in audio as stated above. Not clear why DTVCC1 detects and CC1 (default) doesn't though.
<div class="caption-window ytp-caption-window-bottom" id="caption-window-1" dir="ltr" tabindex="0" aria-live="assertive" lang="en" draggable="true" data-layer="4" style="touch-action: none; text-align: left; left: 2%; bottom: 2.96%;"><span class="captions-text" style="overflow-wrap: normal; display: block;"><span class="caption-visual-line" style="display: block;"><span class="ytp-caption-segment" style="display: inline-block; white-space: pre-wrap; background: rgba(8, 8, 8, 0.75); font-size: 21.1556px; color: rgb(255, 255, 255); fill: rgb(255, 255, 255); font-family: "YouTube Noto", Roboto, "Arial Unicode Ms", Arial, Helvetica, Verdana, "PT Sans Caption", sans-serif;">WE'RE GONNA KICK BUTT.</span></span></span></div>
Alright, from what I can tell, CC1 is using the auto-generated code, and DTVCC1 is using the the more standard audio muting code. In the media that I have observed, DTVCC1 has much better timing for the captions, but that can always vary from source to source. Unfortunately, since the filter is operating on HTML elements available on the page, there isn't much that can be done for the timing. The filter just blindly trusts that whenever the caption is added to the page is the beginning of the audio to match it, and when it is removed it expects that audio to be done.
If you can find an instance where the audio isn't being muted at the same time as the text I'd be interested to see it. Perhaps if you could get a recording (the DVR feature) we could do a screen-share session and try to figure why that might be happening. If it is easily reproducible, then don't worry about recording it. I tried several channels, shows, and I always found that it muted, but the timing was hit-or-miss. Again, I observed that DTVCC1 was much better with timing when it was available.
Anyway, I don't really have much else to go on right now, because it seems to be doing the best it can with the information it has available.
The next step forward will probably be getting the filter to try and load the captions data from YouTube's timedtext api. I haven't had a chance to play around with it yet, but I'm hoping to soon. With that method, it may even be possible to adjust the timing because we will have a start and end time before it gets displayed, much like the cue audio muting mode that is already being employed on several sites.
I will look into other examples. Timedtext API seems promising!
On Tue, May 19, 2020, 01:25 Richard Frost [email protected] wrote:
Alright, from what I can tell, CC1 is using the auto-generated code, and DTVCC1 is using the the more standard audio muting code. In the media that I have observed, DTVCC1 has much better timing for the captions, but that can always vary from source to source. Unfortunately, since the filter is operating on HTML elements available on the page, there isn't much that can be done for the timing. The filter just blindly trusts that whenever the caption is added to the page is the beginning of the audio to match it, and when it is removed it expects that audio to be done.
If you can find an instance where the audio isn't being muted at the same time as the text I'd be interested to see it. Perhaps if you could get a recording (the DVR feature) we could do a screen-share session and try to figure why that might be happening. If it is easily reproducible, then don't worry about recording it. I tried several channels, shows, and I always found that it muted, but the timing was hit-or-miss. Again, I observed that DTVCC1 was much better with timing when it was available.
Anyway, I don't really have much else to go on right now, because it seems to be doing the best it can with the information it has available.
The next step forward will probably be getting the filter to try and load the captions data from YouTube's timedtext api. I haven't had a chance to play around with it yet, but I'm hoping to soon. With that method, it may even be possible to adjust the timing because we will have a start and end time before it gets displayed, much like the cue audio muting mode that is already being employed on several sites.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/richardfrost/AdvancedProfanityFilter/issues/207#issuecomment-630588086, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACAUZHWNRSBHLHGBBZMNCUDRSIJ2XANCNFSM4MRP4HSQ .