本文整理汇总了C++中AEDeviceList::push_back方法的典型用法代码示例。如果您正苦于以下问题:C++ AEDeviceList::push_back方法的具体用法?C++ AEDeviceList::push_back怎么用?C++ AEDeviceList::push_back使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类AEDeviceList
的用法示例。
在下文中一共展示了AEDeviceList::push_back方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: EnumerateOutputDevices
void CPulseAE::EnumerateOutputDevices(AEDeviceList &devices, bool passthrough)
{
if (!m_MainLoop || ! m_Context)
return;
pa_threaded_mainloop_lock(m_MainLoop);
SinkInfoStruct sinkStruct;
sinkStruct.passthrough = passthrough;
sinkStruct.mainloop = m_MainLoop;
sinkStruct.list = &devices;
CStdString def;
def.Format("%s (PulseAudio)",g_localizeStrings.Get(409).c_str());
devices.push_back(AEDevice(def, "pulse:[email protected]"));
WaitForOperation(pa_context_get_sink_info_list(m_Context,
SinkInfo, &sinkStruct), m_MainLoop, "EnumerateAudioSinks");
pa_threaded_mainloop_unlock(m_MainLoop);
}
示例2: EnumerateOutputDevices
void CCoreAudioAEHALOSX::EnumerateOutputDevices(AEDeviceList &devices, bool passthrough)
{
CoreAudioDeviceList deviceList;
CCoreAudioHardware::GetOutputDevices(&deviceList);
std::string defaultDeviceName;
CCoreAudioHardware::GetOutputDeviceName(defaultDeviceName);
std::string deviceName;
for (int i = 0; !deviceList.empty(); i++)
{
CCoreAudioDevice device(deviceList.front());
deviceName = device.GetName();
std::string deviceName_Internal = std::string("CoreAudio:");
deviceName_Internal.append(deviceName);
devices.push_back(AEDevice(deviceName, deviceName_Internal));
deviceList.pop_front();
}
}
示例3: EnumerateDevices
void CAESinkProfiler::EnumerateDevices (AEDeviceList &devices, bool passthrough)
{
devices.push_back(AEDevice("Profiler", "Profiler"));
}