1 #ifndef AL_EFFECTS_EFFECTS_H
2 #define AL_EFFECTS_EFFECTS_H
9 #include "core/effects/base.h"
11 #define DECL_HANDLER(N, T) \
13 using prop_type = T; \
15 static void SetParami(prop_type &props, ALenum param, int val); \
16 static void SetParamiv(prop_type &props, ALenum param, const int *vals); \
17 static void SetParamf(prop_type &props, ALenum param, float val); \
18 static void SetParamfv(prop_type &props, ALenum param, const float *vals);\
19 static void GetParami(const prop_type &props, ALenum param, int *val); \
20 static void GetParamiv(const prop_type &props, ALenum param, int *vals); \
21 static void GetParamf(const prop_type &props, ALenum param, float *val); \
22 static void GetParamfv(const prop_type &props, ALenum param, float *vals);\
24 DECL_HANDLER(NullEffectHandler
, std::monostate
)
25 DECL_HANDLER(ReverbEffectHandler
, ReverbProps
)
26 DECL_HANDLER(StdReverbEffectHandler
, ReverbProps
)
27 DECL_HANDLER(AutowahEffectHandler
, AutowahProps
)
28 DECL_HANDLER(ChorusEffectHandler
, ChorusProps
)
29 DECL_HANDLER(CompressorEffectHandler
, CompressorProps
)
30 DECL_HANDLER(DistortionEffectHandler
, DistortionProps
)
31 DECL_HANDLER(EchoEffectHandler
, EchoProps
)
32 DECL_HANDLER(EqualizerEffectHandler
, EqualizerProps
)
33 DECL_HANDLER(FlangerEffectHandler
, ChorusProps
)
34 DECL_HANDLER(FshifterEffectHandler
, FshifterProps
)
35 DECL_HANDLER(ModulatorEffectHandler
, ModulatorProps
)
36 DECL_HANDLER(PshifterEffectHandler
, PshifterProps
)
37 DECL_HANDLER(VmorpherEffectHandler
, VmorpherProps
)
38 DECL_HANDLER(DedicatedDialogEffectHandler
, DedicatedProps
)
39 DECL_HANDLER(DedicatedLfeEffectHandler
, DedicatedProps
)
40 DECL_HANDLER(ConvolutionEffectHandler
, ConvolutionProps
)
44 using effect_exception
= al::context_error
;
47 /* Default properties for the given effect types. */
48 extern const EffectProps NullEffectProps
;
49 extern const EffectProps ReverbEffectProps
;
50 extern const EffectProps StdReverbEffectProps
;
51 extern const EffectProps AutowahEffectProps
;
52 extern const EffectProps ChorusEffectProps
;
53 extern const EffectProps CompressorEffectProps
;
54 extern const EffectProps DistortionEffectProps
;
55 extern const EffectProps EchoEffectProps
;
56 extern const EffectProps EqualizerEffectProps
;
57 extern const EffectProps FlangerEffectProps
;
58 extern const EffectProps FshifterEffectProps
;
59 extern const EffectProps ModulatorEffectProps
;
60 extern const EffectProps PshifterEffectProps
;
61 extern const EffectProps VmorpherEffectProps
;
62 extern const EffectProps DedicatedDialogEffectProps
;
63 extern const EffectProps DedicatedLfeEffectProps
;
64 extern const EffectProps ConvolutionEffectProps
;
66 #endif /* AL_EFFECTS_EFFECTS_H */