8#include <QMediaDevices>
15namespace swift::misc::audio
123 if (registeredDevice.
isValid())
125 this->
remove(registeredDevice);
149 return static_cast<int>(std::count_if(
165 if (compareDevices.
size() != this->size())
179 const CAudioDeviceInfo d(CAudioDeviceInfo::InputDevice, inputDevice.description());
193 const CAudioDeviceInfo d(CAudioDeviceInfo::OutputDevice, outputDevice.description());
Value object encapsulating information identifying a component of a modular distributed swift process...
bool contains(const T &object) const
Return true if there is an element equal to given object. Uses the most efficient implementation avai...
size_type size() const
Returns number of elements in the sequence.
CSequence findBy(Predicate p) const
int removeIf(Predicate p)
void push_back(const T &value)
Appends an element at the end of the sequence.
int remove(const CAudioDeviceInfo &object)
Value object encapsulating information of a audio device.
bool matchesNameTypeMachineProcess(const CAudioDeviceInfo &device) const
Matching name, type and machine and process.
const QString & getMachineName() const
Machine name.
const QString & getName() const
Get the device name.
DeviceType getType() const
Type.
bool isValid() const
Valid audio device object?
const CIdentifier & getIdentifier() const
Identifier.
CAudioDeviceInfoList findByHostName(const QString &hostName) const
Find by host name.
static QList< QAudioDevice > allQtOutputDevices()
Lists of all available devices.
static QList< QAudioDevice > allQtInputDevices()
Lists of all available devices.
static CAudioDeviceInfoList allInputDevices()
Lists of all available devices.
CAudioDeviceInfoList getOutputDevices() const
Get output devices in that list.
QStringList getDeviceNames() const
All names.
CSequence()=default
Default constructor.
void registerDevice(const CAudioDeviceInfo &device)
Register device.
CAudioDeviceInfo findByNameOrDefault(const QString &name, const CAudioDeviceInfo &defaultDevice, bool strict=false) const
Find by name.
static CAudioDeviceInfoList allOutputDevices()
Lists of all available devices.
void unRegisterDevice(const CAudioDeviceInfo &device)
Un-register device.
static CAudioDeviceInfoList allDevices()
Lists of all available devices.
CAudioDeviceInfoList()=default
Default constructor.
int count(CAudioDeviceInfo::DeviceType type) const
Count (as of type).
static CAudioDeviceInfo defaultOutputDevice()
Lists of all available devices.
static CAudioDeviceInfo defaultInputDevice()
Lists of all available devices.
CAudioDeviceInfoList getInputDevices() const
Get output devices in that list.
bool hasSameDevices(const CAudioDeviceInfoList &compareDevices) const
Has same devices.
static QAudioDevice defaultQtOutputDevice()
Lists of all available devices.
void unRegisterDevices(const CAudioDeviceInfoList &devices)
Un-register devices.
CAudioDeviceInfo findRegisteredDeviceOrDefault(const CAudioDeviceInfo &device) const
Find registered device.
bool isRegisteredDevice(const CAudioDeviceInfo &device) const
Is that a registered device?
static QAudioDevice defaultQtInputDevice()
Lists of all available devices.
CAudioDeviceInfo findByName(const QString &name, bool strict=false) const
Find by name.
void registerDevices(const CAudioDeviceInfoList &devices)
Register devices.
SWIFT_MISC_EXPORT bool stringCompare(const QString &c1, const QString &c2, Qt::CaseSensitivity cs)
String compare.
bool isEmpty() const const
bool startsWith(QChar c, Qt::CaseSensitivity cs) const const
#define SWIFT_DEFINE_SEQUENCE_MIXINS(Namespace, T, List)
Explicit template definition of mixins for a CSequence subclass.