11#ifndef CUSTOM_BUSTYPE_FUNC
15static uint64_t GetAPIBusTypeForChannelIOConfig(
int configIdx,
ERoute dir,
int busIdx,
const IOConfig* pConfig, WDL_TypedBuf<uint64_t>* APIBusTypes)
17 assert(pConfig !=
nullptr);
18 assert(busIdx >= 0 && busIdx < pConfig->NBuses(dir));
20 int numChans = pConfig->
GetBusInfo(dir, busIdx)->NChans();
25 APIBusTypes->Add(kAudioChannelLayoutTag_UseChannelDescriptions | 0);
28 APIBusTypes->Add(kAudioChannelLayoutTag_Mono);
32 APIBusTypes->Add(kAudioChannelLayoutTag_Stereo);
35 APIBusTypes->Add(kAudioChannelLayoutTag_ITU_3_0 | 3);
39 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_4);
40 APIBusTypes->Add(kAudioChannelLayoutTag_Ambisonic_B_Format);
41 APIBusTypes->Add(kAudioChannelLayoutTag_HOA_ACN_SN3D | 4);
44 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_5_0);
48 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_5_1);
49 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_6_0);
53 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_6_1);
54 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_7_0);
55 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_7_1_Front);
59 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_7_1);
60 APIBusTypes->Add(kAudioChannelLayoutTag_AudioUnit_7_1_Front);
62#if defined (MAC_OS_VERSION_11_0)
65 APIBusTypes->Add(kAudioChannelLayoutTag_Atmos_7_1_2);
69 APIBusTypes->Add(kAudioChannelLayoutTag_Atmos_7_1_4);
74 APIBusTypes->Add(kAudioChannelLayoutTag_HOA_ACN_SN3D | numChans);
77 APIBusTypes->Add(kAudioChannelLayoutTag_DiscreteInOrder | numChans);
86extern uint64_t GetAPIBusTypeForChannelIOConfig(
int configIdx, iplug::ERoute dir,
int busIdx,
const iplug::IOConfig* pConfig, WDL_TypedBuf<uint64_t>* APIBusTypes);
ERoute
Used to identify whether a bus/channel connection is an input or an output.
An IOConfig is used to store bus info for each input/output configuration defined in the channel io s...
const IBusInfo * GetBusInfo(ERoute direction, int index) const