aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/backends
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2018-11-15 02:36:05 -0800
committerChris Robinson <[email protected]>2018-11-15 02:36:05 -0800
commit27e7168ad41617d725553bb7234a0149fc711941 (patch)
treefc50044dd50519b58837c17af09157a3c0b6bc61 /Alc/backends
parent1d2cc9017594046570b4b141eae71ea326250604 (diff)
Only declare the device backend stuff with C++
Diffstat (limited to 'Alc/backends')
-rw-r--r--Alc/backends/base.h30
1 files changed, 14 insertions, 16 deletions
diff --git a/Alc/backends/base.h b/Alc/backends/base.h
index bf60a744..75950344 100644
--- a/Alc/backends/base.h
+++ b/Alc/backends/base.h
@@ -24,16 +24,23 @@ inline ALuint64 GetDeviceClockTime(ALCdevice *device)
device->Frequency);
}
+void ALCdevice_Lock(ALCdevice *device);
+void ALCdevice_Unlock(ALCdevice *device);
+
+ClockLatency GetClockLatency(ALCdevice *device);
+
+#ifdef __cplusplus
+} /* extern "C" */
struct ALCbackendVtable;
-typedef struct ALCbackend {
+struct ALCbackend {
const struct ALCbackendVtable *vtbl;
ALCdevice *mDevice;
almtx_t mMutex;
-} ALCbackend;
+};
void ALCbackend_Construct(ALCbackend *self, ALCdevice *device);
void ALCbackend_Destruct(ALCbackend *self);
@@ -95,18 +102,18 @@ static const struct ALCbackendVtable T##_ALCbackend_vtable = { \
}
-typedef enum ALCbackend_Type {
+enum ALCbackend_Type {
ALCbackend_Playback,
ALCbackend_Capture,
ALCbackend_Loopback
-} ALCbackend_Type;
+};
struct ALCbackendFactoryVtable;
-typedef struct ALCbackendFactory {
+struct ALCbackendFactory {
const struct ALCbackendFactoryVtable *vtbl;
-} ALCbackendFactory;
+};
void ALCbackendFactory_deinit(ALCbackendFactory *self);
@@ -155,14 +162,5 @@ ALCbackendFactory *ALCwaveBackendFactory_getFactory(void);
ALCbackendFactory *ALCsdl2BackendFactory_getFactory(void);
ALCbackendFactory *ALCloopbackFactory_getFactory(void);
-
-void ALCdevice_Lock(ALCdevice *device);
-void ALCdevice_Unlock(ALCdevice *device);
-
-ClockLatency GetClockLatency(ALCdevice *device);
-
-#ifdef __cplusplus
-} /* extern "C" */
-#endif
-
+#endif /* __cplusplus */
#endif /* AL_BACKENDS_BASE_H */