aboutsummaryrefslogtreecommitdiffstats
path: root/OpenAL32/Include
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2018-03-05 11:29:03 -0800
committerChris Robinson <[email protected]>2018-03-08 17:48:22 -0800
commit2187316bce826de1eaa6438f688d4713032be3da (patch)
tree44667a0e8d3f21065cb8e8b7c46ab130d274a419 /OpenAL32/Include
parent52dee312702a80974b9a3d8a838faafe65f3e36b (diff)
Use function-like macros to call filter and effect vtable methods
Diffstat (limited to 'OpenAL32/Include')
-rw-r--r--OpenAL32/Include/alEffect.h10
-rw-r--r--OpenAL32/Include/alFilter.h10
2 files changed, 18 insertions, 2 deletions
diff --git a/OpenAL32/Include/alEffect.h b/OpenAL32/Include/alEffect.h
index 4469349c..95fa035e 100644
--- a/OpenAL32/Include/alEffect.h
+++ b/OpenAL32/Include/alEffect.h
@@ -160,11 +160,19 @@ typedef struct ALeffect {
ALeffectProps Props;
- const struct ALeffectVtable *vtbl;
+ const struct ALeffectVtable *vtab;
/* Self ID */
ALuint id;
} ALeffect;
+#define ALeffect_setParami(o, c, p, v) ((o)->vtab->setParami(o, c, p, v))
+#define ALeffect_setParamf(o, c, p, v) ((o)->vtab->setParamf(o, c, p, v))
+#define ALeffect_setParamiv(o, c, p, v) ((o)->vtab->setParamiv(o, c, p, v))
+#define ALeffect_setParamfv(o, c, p, v) ((o)->vtab->setParamfv(o, c, p, v))
+#define ALeffect_getParami(o, c, p, v) ((o)->vtab->getParami(o, c, p, v))
+#define ALeffect_getParamf(o, c, p, v) ((o)->vtab->getParamf(o, c, p, v))
+#define ALeffect_getParamiv(o, c, p, v) ((o)->vtab->getParamiv(o, c, p, v))
+#define ALeffect_getParamfv(o, c, p, v) ((o)->vtab->getParamfv(o, c, p, v))
inline ALboolean IsReverbEffect(ALenum type)
{ return type == AL_EFFECT_REVERB || type == AL_EFFECT_EAXREVERB; }
diff --git a/OpenAL32/Include/alFilter.h b/OpenAL32/Include/alFilter.h
index e28b7b2b..4e506722 100644
--- a/OpenAL32/Include/alFilter.h
+++ b/OpenAL32/Include/alFilter.h
@@ -157,11 +157,19 @@ typedef struct ALfilter {
ALfloat GainLF;
ALfloat LFReference;
- const struct ALfilterVtable *vtbl;
+ const struct ALfilterVtable *vtab;
/* Self ID */
ALuint id;
} ALfilter;
+#define ALfilter_setParami(o, c, p, v) ((o)->vtab->setParami(o, c, p, v))
+#define ALfilter_setParamf(o, c, p, v) ((o)->vtab->setParamf(o, c, p, v))
+#define ALfilter_setParamiv(o, c, p, v) ((o)->vtab->setParamiv(o, c, p, v))
+#define ALfilter_setParamfv(o, c, p, v) ((o)->vtab->setParamfv(o, c, p, v))
+#define ALfilter_getParami(o, c, p, v) ((o)->vtab->getParami(o, c, p, v))
+#define ALfilter_getParamf(o, c, p, v) ((o)->vtab->getParamf(o, c, p, v))
+#define ALfilter_getParamiv(o, c, p, v) ((o)->vtab->getParamiv(o, c, p, v))
+#define ALfilter_getParamfv(o, c, p, v) ((o)->vtab->getParamfv(o, c, p, v))
void ReleaseALFilters(ALCdevice *device);