[wdmaudiodev] Re: Can I identify my audio endpoint?

  • From: "Michael R. Preston" <mike@xxxxxxxxxxxxxxxxxxx>
  • To: wdmaudiodev@xxxxxxxxxxxxx
  • Date: Thu, 26 Oct 2006 15:45:59 -0700

Frank, see my questions below. I want to answer Ally's question first, then I have a question for you...

In the INF file that came with the Swap APO sample code, there are examples of how to put values into both the FX property store, and the endpoint property store. Entries to go into the FX property store get a label of "FX\\0", and entries to go into the endpoint property store get a label of "EP\\0". The following is taken from the aforementioned INF file:

;;
;; All FX\\0 entries in the same grouping
;;
[SysFx.AddReg]
HKR,"FX\\0",%PKEY_DisplayName%,,%SYSFX_FriendlyName%
HKR,"FX\\0",%PKEY_SYSFX_PreMixClsid%,,%SYSFX_PREMIX_CLSID%
HKR,"FX\\0",%PKEY_SYSFX_PostMixClsid%,,%SYSFX_POSTMIX_CLSID%
HKR,"FX\\0",%PKEY_SYSFX_UiClsid%,,%SYSFX_UI_CLSID%
HKR,"FX\\0",%PKEY_SYSFX_Association%,,%KSNODETYPE_ANY%

;;
;; All EP\\0 entries in the same grouping
;;
;; Set default format to 48kHz, 16-bit, Stereo
;; Add endpoint extension property page
;;
[OEMSettingsOverride.AddReg]
HKR,"EP\\0",%PKEY_AudioEndpoint_Association%,,%KSNODETYPE_SPEAKER%
HKR,"EP\\0",%PKEY_AudioEngine_OEMFormat%,%REG_BINARY%,41,00,8C,70,28,00,00,00,FE,FF,02,00,80,BB,00,00,00,EE,02,00,04,00,10,00,16,00,10,00,03,00,00,00,01,00,00,00,00,00,10,00,80,00,00,AA,00,38,9B,71
HKR,"EP\\0",%PKEY_AudioEndpoint_Ext_UiClsid%,,%AUDIOENDPOINT_EXT_UI_CLSID%


The reason I'm bringing this up, is that I think there may be a problem with this mechanism. I'm running on a system with more than one playback endpoint (Speakers, Headphones, and S/PDIF). I can see entries destined for the FX property store get populated for all endpoints. However, entries destined for the endpoint property store only seem to get populated for the first (default) endpoint. Frank, is this a known problem? Any comments or suggestions?


Thanks,
Mike

Alexandra Schoepel (Ally) wrote:
Hi Frank,
Regarding setting a special property to help us locate our endpoint: as far as I can tell, the sysfx example adds properties to the FX PROPERTIES key in the registry, but not the 'standard' one, e.g.
..\MMDevices\Audio\Render\{DS GUID}\Properties\
Am I missing something, or does the example only demonstrate adding properties for the effects? It looks to me the only way to find the endpoint associated with an audio driver is by the device name/description from the inf.
Thanks,
Ally


------------------------------------------------------------------------
*From:* wdmaudiodev-bounce@xxxxxxxxxxxxx [mailto:wdmaudiodev-bounce@xxxxxxxxxxxxx] *On Behalf Of *Frank Yerrace
*Sent:* Wednesday, October 18, 2006 3:53 PM
*To:* wdmaudiodev@xxxxxxxxxxxxx
*Subject:* [wdmaudiodev] Re: Can I identifying my audio endpoint?


I’m sorry I misled you with my previous response. A colleague reminded me that PKEY_Endpoint_KsComponentId is not generally available in the endpoint property stores. Another alternative- similar in concept- is for your device INF to indirectly populate the endpoint property stores with your own custom properties. The SYSFX sample demonstrates this. (Sorry I don’t have a pointer to the SYSFX sample or documentation at my fingertips. I believe it’s been referenced in other messages to this mailing list.) Then your app can search for an endpoint that has your custom properties in its property store.



Frank Yerrace

Microsoft Corporation

This posting is provided "AS IS" with no warranties, and confers no rights.



------------------------------------------------------------------------

*From:* wdmaudiodev-bounce@xxxxxxxxxxxxx [mailto:wdmaudiodev-bounce@xxxxxxxxxxxxx] *On Behalf Of *Alexandra Schoepel (Ally)
*Sent:* Tuesday, October 17, 2006 4:12 PM
*To:* wdmaudiodev@xxxxxxxxxxxxx
*Subject:* [wdmaudiodev] Re: Can I identifying my audio endpoint?




Yes it does. Okay, very cool. Is this key defined in a standard header or is there a section of documentation describing how the KSCOMPONENTID is encapsulated in the PROPVARIANT so I don't bother you any more. :)



Thanks again,

Alexandra Schoepel



------------------------------------------------------------------------

*From:* wdmaudiodev-bounce@xxxxxxxxxxxxx [mailto:wdmaudiodev-bounce@xxxxxxxxxxxxx] *On Behalf Of *Frank Yerrace
*Sent:* Tuesday, October 17, 2006 3:59 PM
*To:* wdmaudiodev@xxxxxxxxxxxxx
*Subject:* [wdmaudiodev] Re: Can I identifying my audio endpoint?


Does your device have its own audio driver? One alternative is to read PKEY_Endpoint_KsComponentId from the endpoint property store. This returns a KSCOMPONENTID structure. However, for this endpoint property to have useful information, the audio driver must support the KS property KSPROPERTY_GENERAL_COMPONENTID and fill it in with useful information.



Frank Yerrace

Microsoft Corporation



This posting is provided "AS IS" with no warranties, and confers no rights.





------------------------------------------------------------------------

*From:* wdmaudiodev-bounce@xxxxxxxxxxxxx [mailto:wdmaudiodev-bounce@xxxxxxxxxxxxx] *On Behalf Of *Alexandra Schoepel (Ally)
*Sent:* Tuesday, October 17, 2006 3:27 PM
*To:* wdmaudiodev@xxxxxxxxxxxxx
*Subject:* [wdmaudiodev] Can I identifying my audio endpoint?




Hi guys,

What is the most effective way to identify one's own audio endpoint when using the IMMDeviceEnumerator? None of the published Audio Endpoint properties seem to be uniquely tied to the device. The DirectSound GUID (PKEY_AudioEndpoint_GUID) seems to be a floating value assigned by the OS and in no way tied to any information in the inf file of the driver. Additionally, help on the IMMDevice::GetId function states that the information it represents is opaque and should not be used to obtain information about the device. Any advice?

Thanks,
Alexandra Schoepel


-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | Mike Preston | Home/Office: (360)756-1655 | | E-mail: mike@xxxxxxxxxxxxxxxxxxx | Cell: (360)303-9331 | |~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| | The man who follows the crowd will usually get no | | further than the crowd. The man who walks alone is | | likely to find himself in places no one has ever been. | | -- Alan Ashley-Pitt | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ******************

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: