summaryrefslogtreecommitdiffstats
path: root/pica-client/audiodevice.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'pica-client/audiodevice.cpp')
-rw-r--r--pica-client/audiodevice.cpp29
1 files changed, 29 insertions, 0 deletions
diff --git a/pica-client/audiodevice.cpp b/pica-client/audiodevice.cpp
index d2995e3..17dd1b9 100644
--- a/pica-client/audiodevice.cpp
+++ b/pica-client/audiodevice.cpp
@@ -1,3 +1,19 @@
+/*
+ (c) Copyright 2012 - 2018 Anton Sviridenko
+ https://picapica.im
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, version 3.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <https://www.gnu.org/licenses/>.
+*/
#include "audiodevice.h"
#ifdef Q_OS_LINUX
@@ -68,3 +84,16 @@ QList<MediaDeviceInfo> AudioDevice::Enumerate(enum MediaDeviceStreamDirection di
#endif
return result;
}
+
+QString AudioDevice::PlatformDriverName()
+{
+#if defined(Q_OS_LINUX)
+ return QStringLiteral("alsa");
+#elif defined(Q_OS_MACOS) || defined(Q_OS_MAC)
+ return QStringLiteral("audiotoolbox");
+#elif defined(Q_OS_WIN)
+ return QStringLiteral("dsound");
+#else
+ return QStringLiteral("oss");
+#endif
+}