summaryrefslogtreecommitdiffstats
path: root/src/soundio/sounddeviceerror.h
diff options
context:
space:
mode:
authorDaniel Schürmann <daschuer@mixxx.org>2016-10-22 00:42:13 +0200
committerDaniel Schürmann <daschuer@mixxx.org>2016-10-22 00:44:36 +0200
commit0a536ce82afe84fe34090e5347c0a19be1dc24da (patch)
tree9f57aa80e0cbf70df726d857f62dfdf35646d8ef /src/soundio/sounddeviceerror.h
parentc2d485130beb5c4305029094f276ce3860db0598 (diff)
Use enum SoundDeviceError in all SoundDevice callers. This fixes suspicious casts to enum Result
Diffstat (limited to 'src/soundio/sounddeviceerror.h')
-rw-r--r--src/soundio/sounddeviceerror.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/soundio/sounddeviceerror.h b/src/soundio/sounddeviceerror.h
new file mode 100644
index 0000000000..1157ebd5fb
--- /dev/null
+++ b/src/soundio/sounddeviceerror.h
@@ -0,0 +1,13 @@
+#ifndef SOUNDDEVICEERROR_H
+#define SOUNDDEVICEERROR_H
+
+// Used for returning errors from sounddevice functions.
+enum SoundDeviceError {
+ SOUNDDEVICE_ERROR_ERR = -1,
+ SOUNDDEVICE_ERROR_OK = 0,
+ SOUNDDEVICE_ERROR_DUPLICATE_OUTPUT_CHANNEL,
+ SOUNDDEVICE_ERROR_EXCESSIVE_OUTPUT_CHANNEL,
+ SOUNDDEVICE_ERROR_EXCESSIVE_INPUT_CHANNEL,
+};
+
+#endif /* SOUNDDEVICEERROR_H */