Re: Finding the attached Device Endpoint for External Devices
Re: Finding the attached Device Endpoint for External Devices
- Subject: Re: Finding the attached Device Endpoint for External Devices
- From: Doug Wyatt <email@hidden>
- Date: Tue, 12 Jul 2005 10:15:08 -0700
The code snippet below traverses and prints an endpoint's
connections, which are the uniqueID's of the connected objects. If
the endpoint is a device endpoint, the connections are to external
device endpoints. And vice versa.
if (!MIDIObjectGetDataProperty(obj,
kMIDIPropertyConnectionUniqueID, &cfdata)) {
const SInt32 *p = (SInt32 *)CFDataGetBytePtr(cfdata);
int n = CFDataGetLength(cfdata) / sizeof(SInt32);
if (n > 0) {
printf("connections:");
while (--n >= 0) {
printf(" 0xlX", EndianU32_BtoN(*p));
++p;
}
printf("\n");
}
CFRelease(cfdata);
}
--
Doug Wyatt
Core Audio, Apple
On Jul 11, 2005, at 18:31, John Pitcairn wrote:
If the user has specified (as in AudioMIDISetup) that an
ExternalDevice is attached to a Device endpoint, how would I go
about finding that Device endpoint, given the ExternalDevice endpoint?
Similarly, can I find all ExternalDevices attached to a given
Device endpoint, given only the Device endpoint?
--
John Pitcairn
----------------------------------------------------------------------
----
Revolver Design | Opus Locus | Auckland, New Zealand
----------------------------------------------------------------------
----
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40apple.com
This email sent to email@hidden
_______________________________________________
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