Re: Event for plug / unplug headphones?
Re: Event for plug / unplug headphones?
- Subject: Re: Event for plug / unplug headphones?
- From: "David M. Cotter" <email@hidden>
- Date: Fri, 15 Sep 2006 16:08:44 -0700
That implies that the device in question doesn't support a jack
control, which isn't at all unusual.
even for the built in headphone jack on an aluminum PowerBook G4?
and if that's the case, shouldn't the "add property listener"
function return an error, like "i can't do this, sorry"?
if I"m trying to get the build in headphone jack, is
"kAudioHardwarePropertyDefaultOutputDevice" the proper value?
On Sep 15, 2006, at 3:55 PM, David M. Cotter wrote:
i did this:
UInt32 dataSize = sizeof(AudioDeviceID);
i_outDeviceID = kAudioDeviceUnknown;
ERR(AudioHardwareGetProperty
(kAudioHardwarePropertyDefaultOutputDevice, &dataSize, (void *)
&i_outDeviceID));
ERR(AudioDeviceAddPropertyListener(
i_outDeviceID,
kAudioPropertyWildcardChannel,
false,
kAudioDevicePropertyJackIsConnected,
JackPlugged,
this));
and it returns no error, but my function is not called?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden