2013-11-21 145 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来查找设备。如果实体或设备为零,则端点可能是“虚拟”的。