2013-11-21 143 views

回答

1

這裏是我指着OMAC谷歌團的溶液(感謝傑西·查普爾

static BOOL isVirtualEndpoint(MIDIEndpointRef ref) 
{ 
    MIDIEntityRef entity = 0; 

    MIDIEndpointGetEntity(ref, &entity); 
    if (entity) 
    { 
     return NO; 
    } 
    else 
    { 
    return YES; 
    } 
} 
2

MIDIEndpointRef開始,請嘗試使用MIDIEndpointGetEntity,然後使用MIDIEntityGetDevice來查找設備。如果實體或設備爲零,則端點可能是「虛擬」的。