[wdmaudiodev] Re: setting sample rate in the control panel in Vista

  • From: Eugene Gavrilov <egavrilov@xxxxxxxxxxxxx>
  • To: Chris W <wdmaudiodev@xxxxxxxxxxxxx>
  • Date: Mon, 29 Oct 2007 13:15:06 +0300

Hello Chris,

> There is very simple way to set default format in Vista:
> - set value PKEY_AudioEngine_DeviceFormat
> - set value PKEY_AudioEngine_MixFormat
> Both values are type VT_BLOB, value WAVEFORMATEXTENSIBLE.
> Mixer in Vista is 32 bit - you should set properly
> nAvgBytesPerSec,nBlockAlign,wBitsPerSample,Samples.
> Use GetValue function and cast pBlobData for WAVEFORMATEXTENSIBLE to look
> how system do it.

Yes,  you are right, but in order to change PKEY_ values administrator
privileges are required. Moreover, Mitchell Rundle said earlier:

> You cannot set the device format via the propertyStore alone as this will 
> cause
> the internal state of various audio core components to be out of sync.


Regards,
 Eugene Gavrilov
 Senior Software Engineer,
 CEntrance, Inc.

******************

WDMAUDIODEV addresses:
Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
Unsubscribe:  mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx

URL to WDMAUDIODEV page:
http://www.wdmaudiodev.com/

Other related posts: