cyfung1031 / userscript-supports

This is for the userscripts created on GreasyFork.org.
https://cyfung1031.github.io/userscript-supports/
MIT License
48 stars 2 forks source link

Disable volume stable is broken. #47

Closed ChromiaCat closed 1 month ago

cyfung1031 commented 1 month ago

Please explain more because I cannot see your YouTube UI.

For me, this is an option in video player menu for some videos like https://www.youtube.com/watch?v=TIWRbR69Cjc.

By using https://greasyfork.org/en/scripts/494252-youtube-disable-volume-stable, the option should be removed.

Please describe what do you mean "Disable volume stable is broken."

The option is not removed? Since recent?

ChromiaCat commented 1 month ago

Without using your script, the Stable Volume toggle is there but disabled, document.querySelector("video").volume reports 0.702263367991081 for the video https://www.youtube.com/watch?v=XaabCdyQ-mA

Using your script, the toggle is gone but document.querySelector("video").volume still reports an actual or "Normalized" volume of 0.702263367991081

But using https://gist.github.com/RobotoSkunk/212fab73afa6df48f9438b56e18ba073 it does bring the document.querySelector("video").volume to a 1 and combining your script removes the toggle too.

Edit: As a side note, using other scripts causes the sound to "crackle" for some reason, using yours iirc didn't cause that.

cyfung1031 commented 1 month ago

They are totally two different things!

Volume Normalization

YouTube's volume normalization is a standard feature since long time ago.

There is an old script - YouTube Volume Curve Designer (year 2020) for the volume changing. ( not disabling the volume normalization ) (The idea for YouTube Volume Curve Designer is that volume control should not be linear as our hearing cannot sense the linear difference. For example, 70% and 80% is nearly the same loundness as per human hearing)

Since the normalization is a standard feature so disabling it is not recommended. By disabling it, you will experience a volume setting different from other audiences.

(So I don't have any script to disable this feature. I have checked your provided link. That script is not doing the correct way so the sound might "crackle".)

Volume Stable

This is a new feature since 2023 I guess. (A/B testing ended in 2024)

(Not available to old videos, as there was no AI to analyze the video)

YouTube uses AI to prevent the sudden volume change. This would affect watching music video a lot.

My script is to disable this feature.

Currently, this is a visible option in player's menu. As it is an enhancement feature, users are able to toggle it off without any script.

Userscript "YouTube Volume Assistant"

I have created a userscript previously to show the normalized volume when user is changing the volume. You can install it to see the actual volume.

Screen Shot 2024-07-12 at 7 36 43

Big Remarks

I would say that, the author of "https://gist.github.com/RobotoSkunk/212fab73afa6df48f9438b56e18ba073" does not understand the design of YouTube engineer. The normalization feature is standard. Youtube's 100% is not video element's volume 100%. This is just the difference in definition. You can make it more or less using "YouTube Volume Curve Designer". But you should be reminded that the standard youtube 100% is the original "Youtube's 100%"

Make Youtube's 100% become media volume 100%

I don't think this is really necessary. You can use the curve feature in YouTube Volume Curve Designer to freely make the volume much higher or much lower.

For some people who have OCD, you can use YouTube Volume Curve Designer to set the volume gain to 1.5. which would give you 105.3%

Screen Shot 2024-07-12 at 8 57 17
  100% (slider bar)
  -> normalized volume: 70% (youtube standard design)
  -> actual volume: 70% * 1.5 = 105% ( customized 1.5 gain )