[AC97] Use individual Decibel range for Master Volume control (#6950)

Add ReactOS change to use the same Decibel (dB) sound loudness range for Master Volume control as for WaveOut Volume Control.
This fixes incompatible volume level change scaling when changing the volume in Fox Audio Player 0.10.2 from Rapps and Winamp 2.95 with WaveOut output plugin.
Now it is identical to the one when using original AC97 driver from Windows XP/Server 2003.
CORE-14780
This commit is contained in:
Oleg Dubinskiy 2024-06-01 12:31:53 +02:00 committed by GitHub
parent 9046cc97ee
commit a55e9ce19c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -170,7 +170,9 @@ NTSTATUS CAC97MiniportTopology::GetDBValues
{
// These nodes could have 5bit or 6bit controls, so we first
// have to check this.
#ifndef __REACTOS__
case NODE_MASTEROUT_VOLUME:
#endif
case NODE_FRONT_VOLUME:
case NODE_HPOUT_VOLUME:
case NODE_SURROUND_VOLUME:
@ -230,6 +232,11 @@ NTSTATUS CAC97MiniportTopology::GetDBValues
case NODE_VIDEO_VOLUME:
case NODE_AUX_VOLUME:
case NODE_WAVEOUT_VOLUME:
#ifdef __REACTOS__
// ReactOS change: use the same Decibel range as for WaveOut,
// to fix incorrect volume level change scaling. CORE-14780
case NODE_MASTEROUT_VOLUME:
#endif
*plMaximum = 0x000C0000; // 12 dB
*plMinimum = 0xFFDD8000; // -34.5 dB
*puStep = 0x00018000; // 1.5 dB