[wdmaudiodev] Re: Setting default subdevice in Vista

  • From: Matt Gonzalez <matt@xxxxxxxxxxxxx>
  • To: wdmaudiodev@xxxxxxxxxxxxx
  • Date: Wed, 07 Nov 2007 08:14:07 -0800

Can this be done programatically from within the driver? My driver creates all its interfaces dynamically.


Mitchell Rundle wrote:
The trick is to get the PKEY_AudioDevice_SetupPreferred property set in the 
endpoint propertystore for the endpoint that you want to be default.

1) Remove the SetupPrefferedAudioDevices registry setting from you INF.  It is 
not precise enough.
2) For the subdevice that you want to be default add the following registry 
entries:

HKR,"EP\\0", %PKEY_AudioEndpoint_Association%,,%KSNODETYPE_SPEAKER%
HKR,"EP\\0", %PKEY_AudioDevice_SetupPreferred%, %REG_DWORD%,1

3) add to the strings section of the inf

PKEY_AudioEndpoint_Association  = "{1DA5D803-D492-4EDD-8C23-E0C0FFEE7F0E},2"
PKEY_AudioDevice_SetupPreferred = "{F3E80BEF-1723-4FF2-BCC4-7F83DC5E46D4},1"


Regards,
Mitch Rundle
Microsoft Corporation

This posting is provided "as is" with no warrantees, and confers no rights.


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

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: