VirtualBox

Changeset 91577 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Oct 5, 2021 4:55:53 PM (3 years ago)
Author:
vboxsync
Message:

Audio/Validation Kit: Sketched out setting the system's master volume on Windows via WASAPI (not enabled yet) [SCM fix]. ​bugref:10008

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/utils/audio/vkatCommon.cpp

    r91576 r91577  
    142142    CLSID CLSID_const MMDeviceEnumerator =_uuidof(MMDeviceEnumerator);
    143143    IID IID_const IMMDeviceEnumerator = uuidof(IMMDeviceEnumerator);
    144         IMMDeviceEnumerator* pEnumerator;
    145         HRESULT hr = CoCreateInstance(CLSID_MMDeviceEnumerator, NULL, CLSCTX_ALL, IID_IMMDeviceEnumerator, (void**)&pEnumerator);
     144    IMMDeviceEnumerator* pEnumerator;
     145    HRESULT hr = CoCreateInstance(CLSID_MMDeviceEnumerator, NULL, CLSCTX_ALL, IID_IMMDeviceEnumerator, (void**)&pEnumerator);
    146146    IMMDevice *pDevice;
    147         hr = pEnumerator->GetDefaultAudioEndpoint(EDataFlow::eRender, ERole::eConsole, &pDevice);
     147    hr = pEnumerator->GetDefaultAudioEndpoint(EDataFlow::eRender, ERole::eConsole, &pDevice);
    148148    IAudioSessionManager *pManager;
    149         IID IID_const IMMAudioSessionManager = uuidof(IAudioSessionManager);
    150         hr = pDevice->Activate(IID_IMMAudioSessionManager, CLSCTX_ALL, NULL, (void**)&pManager);
    151         ISimpleAudioVolume *pSimpleAudioVolume;
    152         hr = pManager->GetSimpleAudioVolume(NULL, true, &pSimpleAudioVolume);
     149    IID IID_const IMMAudioSessionManager = uuidof(IAudioSessionManager);
     150    hr = pDevice->Activate(IID_IMMAudioSessionManager, CLSCTX_ALL, NULL, (void**)&pManager);
     151    ISimpleAudioVolume *pSimpleAudioVolume;
     152    hr = pManager->GetSimpleAudioVolume(NULL, true, &pSimpleAudioVolume);
    153153    pSimpleAudioVolume->SetMasterVolume(1.0);
    154154#endif
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette