Changeset 107592 in vbox for trunk/src/VBox/Devices
- Timestamp:
- Jan 9, 2025 11:31:47 AM (2 months ago)
- svn:sync-xref-src-repo-rev:
- 166665
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevIchAc97.cpp
r107591 r107592 3183 3183 */ 3184 3184 bool const fCtlMuted = (uVal >> AC97_BARS_VOL_MUTE_SHIFT) & 1; 3185 # ifdef VBOX_WITH_AC97_GAIN_SUPPORT 3185 3186 uint8_t uCtlGainLeft = (uVal >> 8) & AC97_BARS_GAIN_MASK; 3186 3187 uint8_t uCtlGainRight = uVal & AC97_BARS_GAIN_MASK; 3187 3188 3188 Assert(uCtlGainLeft <= 255 / AC97_DB_FACTOR); 3189 3189 Assert(uCtlGainRight <= 255 / AC97_DB_FACTOR); 3190 LogFunc(("uCtlGainLeft=%RU8, uCtlGainRight=%RU8 ", uCtlGainLeft, uCtlGainRight)); 3191 # endif 3190 3192 3191 3193 LogFunc(("index=0x%x, uVal=%RU32, enmMixerCtl=%RU32\n", index, uVal, enmMixerCtl)); 3192 LogFunc(("uCtlGainLeft=%RU8, uCtlGainRight=%RU8 ", uCtlGainLeft, uCtlGainRight));3193 3194 3194 3195 uint8_t lVol; … … 3198 3199 * for the recording input, the best we can do is set the maximum volume. 3199 3200 */ 3200 # ifndef VBOX_WITH_AC97_GAIN_SUPPORT 3201 # ifdef VBOX_WITH_AC97_GAIN_SUPPORT 3202 lVol = PDMAUDIO_VOLUME_MAX + uCtlGainLeft * AC97_DB_FACTOR; 3203 rVol = PDMAUDIO_VOLUME_MAX + uCtlGainRight * AC97_DB_FACTOR; 3204 # else 3201 3205 /* NB: Currently there is no gain support, only attenuation. Since AC'97 does not 3202 3206 * support attenuation for the recording inputs, the best we can do is set the … … 3204 3208 */ 3205 3209 lVol = rVol = PDMAUDIO_VOLUME_MAX; 3206 # else3207 lVol = PDMAUDIO_VOLUME_MAX + uCtlGainLeft * AC97_DB_FACTOR;3208 rVol = PDMAUDIO_VOLUME_MAX + uCtlGainRight * AC97_DB_FACTOR;3209 3210 # endif 3210 3211
Note:
See TracChangeset
for help on using the changeset viewer.