PandaDriver156 / Custom-Volume-Range

Powercord/Replugged plugin that lets you set the volume of users and screenshares over 200%
MIT License
8 stars 4 forks source link

Custom Volume Range destroys audio quality #5

Open NyxIsBad opened 2 years ago

NyxIsBad commented 2 years ago

Basically what title says - this occurs with just custom volume range on (for volumes under 200%, i.e. 92% as well)

Audio sounds underwater, can't seem to handle high pitches and trills. May be an unintentional drop in bitrate if you're passing the audio through some filter to achieve the audio boost?

PandaDriver156 commented 2 years ago

Are you sure this only happens when the plugin is enabled? Custom volume range doesn't modify audio, just patches the volume slider to allow higher values

NyxIsBad commented 2 years ago

Yep. That's odd if that's the case though. I know it's not placebo since both myself and a few friends with the plugin noticed it and all had no issues after it was off, then issues again when on. Maybe some weird behavior from discord is causing this

PandaDriver156 commented 2 years ago

Interesting. I'll have a look at it

PandaDriver156 commented 2 years ago

Me and my friend tested it and we couldn't see a difference in audio quality when the plugin was on/off. Could you tell a bit about your setup? Mainly operating system, Discord release channel, mods used, whether you use custom volume range through powercord or goosemod, and other plugins enabled

NyxIsBad commented 2 years ago

Yeah sure, I'll send both mine and my friends. Both of us use windows 10 for starters.

image My build info ^ (should be pretty typical, I hope)

# Debugging Information | Result created: Sat, 05 Mar 2022 13:44:41 GMT

[SYSTEM / DISCORD]
Locale="en-US"
OS="Windows 64-bit"
Architecture="x64"
ReleaseChannel="canary"
AppVersion="1.0.45"
BuildNumber="117519"
BuildID="c1e9073"
Experiments="2/101"

[PROCESS VERSIONS]
React="17.0.2"
Electron="13.6.6"
Chrome="91.0.4472.164"
Node="14.16.0"

[POWERCORD]
Commands="7"
Settings="55"
Plugins="11/58"
Themes="1/5"
Labs="0/4"
SettingsSync="false"
CachedFiles="1042"
Account="false"
APIs="9"

[GIT]
Upstream="Official"
Revision="[8b99354]"
Branch="v2"
Latest="true"

[LISTINGS]
PowercordPath="C:\Users\N**\powercord"
DiscordPath="C:\Users\N**\AppData\Local\DiscordCanary\app-1.0.45"
Experiments="2021-08_gif_creator, 2021-07_role_popout"
Labs=""
Plugins="Custom-Volume-Range, PersistFavourites"

My debug information ^ The theme I am using is ClearVision-v6 (as was/is my friend, both at the time of reporting this and now). As one of the developers, I'm was pretty certain this doesn't affect your plugin in the first place, and after unloading the theme and reloading discord I'm pretty certain this is the case.

This is not my usual setup. However, this is the bare minimum setup (+Persist Favorites because I've been reloading discord to check and I didn't want to lose my gifs) that I needed to get the bug to replicate. I'm reasonably certain that Persist Favorites is not the conflicting plugin here, but I can try it in a bit after saving my gifs somewhere

# Debugging Information | Result created: Sat, 19 Feb 2022 00:48:50 GMT

[SYSTEM / DISCORD]
Locale="en-US"
OS="Windows 64-bit"
Architecture="x64"
ReleaseChannel="canary"
AppVersion="1.0.45"
BuildNumber="115515"
BuildID="e5f2092"
Experiments="0/114"

[PROCESS VERSIONS]
React="17.0.2"
Electron="13.6.6"
Chrome="91.0.4472.164"
Node="14.16.0"

[POWERCORD]
Commands="30"
Settings="5"
Plugins="34/38"
Themes="1/2"
Labs="0/4"
SettingsSync="false"
CachedFiles="438"
Account="false"
APIs="9"

[GIT]
Upstream="Official"
Revision="[f254d55]"
Branch="v2"
Latest="true"

[LISTINGS]
PowercordPath="C:\Users\A****\powercord"
DiscordPath="C:\Users\A****\AppData\Local\DiscordCanary\app-1.0.45"
Experiments=""
Labs=""
Plugins="Custom-Volume-Range, In-app-notifs, message-link-embed, powercord-dateviewer, PowercordPluginDownloader, PowercordThemeDownloader, quick-search, scrollable-autocomplete, silent-typing, theme-toggler, time-in-pc, user-details, vpc-shiki, Wolfram, wpm, pronoundb-powercord"

Here was my friend's debug information at the time we found the bug ^ I couldn't get a more current version of his debug out of him. I hope this is useful still

In addition, I don't know if you care at all about the chat logs between my friend and I, but here they are. I was testing the sound quality through jockie bot with the Gormott OST from Xenoblade Chronicles 2 because it contained a lot of trilling towards the start of the song that frequently sounded underwater to me. I had initially believed it to be a fault with jockie bot, because I didn't hear issues in normal vc with others (presumably because people don't trill like a flute when they're speaking lol)

We're both using Canary and powercord.

PandaDriver156 commented 2 years ago

Even with using the same bot on the same track, i can't hear a difference with the plugin on vs off. Here is a short clip comparing the two (don't mind the audio stuttering, it's probably just some network issue)

If you think it's definitely related to this plugin and the difference is noticable then I'd appreciate a short video comparing them.

Good soundtrack by the way

NyxIsBad commented 2 years ago

The audio stutter I'm aware of that's actually part of the actual soundtrack I think so no worries I'll try to record a clip right now

NyxIsBad commented 2 years ago

I believe I've found a way to replicate Edit: never mind, I haven't seems completely random lmao

The issue is that the audio distortion seems to have some "permanence" to it. It doesn't begin until the plugin is turned on, but persists even after the plugin is turned off (and indeed even after hard reloads) and doesn't stop until powercord is unplugged. I'm almost beginning to think this is also powercord's fault somehow

NyxIsBad commented 2 years ago

After an EXCEEDINGLY frustrating two hours or so,

Here are the clip(s) (more than one because I was forgetful): (Only plugin on/off is custom volume range) Here is the song I was using Here is powercord with no plugins And here is the longer comparison between web and powercord with it on Hopefully those clips illustrate the effect the bug has at least (buzzing sound, louder, feels like a bee is sitting on your earlobe kinda feeling)

You can (inconsistently) replicate it by turning on the plugin, setting a volume >200% (greater than discord allows, like 400%), then reloading the app. Discord seems to "remember" the amplification if you disable the plugin after reload and then reload again and accordingly destroys the audio quality in the same way turning music up to 400% (or however much % you had set to before) normally would.

Although this seems like a ridiculous set of steps to follow, it's actually something that I'm sure is easily triggerable by accident if you were to use the function the plugin provides and then disable it at some point only to reenable it again. However, this really doesn't seem to be a problem you can fix. Instead, it should probably just be treated as an issue with discord. It's interesting to note that if you unplug powercord while your discord is bugged out in this state, the bug goes away.

The only way to resolve the bug is to disable plugin in the settings and then hard reset discord (system tray, task manager, or delete roaming folder lmao), or to disable powercord entirely.

After that point, sound returns back to normal.

NyxIsBad commented 2 years ago

Sound is always at 100% on all the clips above. No insane 400% amplifier to the sound causing weird sound quality supposedly, although the bug causes it anyway.

I have no clue how this is meant to be fixed. I'm sorry for wasting your time if this isn't fixable at all

NyxIsBad commented 2 years ago

Ignore what I'm doing to the volume bar at 0:40 or so by the way I'm just trying to make the volume exactly 100%