summaryrefslogtreecommitdiff
path: root/servers/audio/effects/audio_effect_eq.h
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-03-05 16:44:50 +0100
committerRémi Verschelde <rverschelde@gmail.com>2017-03-05 16:44:50 +0100
commit5dbf1809c6e3e905b94b8764e99491e608122261 (patch)
tree5e5a5360db15d86d59ec8c6e4f7eb511388c5a9a /servers/audio/effects/audio_effect_eq.h
parent45438e9918d421b244bfd7776a30e67dc7f2d3e3 (diff)
A Whole New World (clang-format edition)
I can show you the code Pretty, with proper whitespace Tell me, coder, now when did You last write readable code? I can open your eyes Make you see your bad indent Force you to respect the style The core devs agreed upon A whole new world A new fantastic code format A de facto standard With some sugar Enforced with clang-format A whole new world A dazzling style we all dreamed of And when we read it through It's crystal clear That now we're in a whole new world of code
Diffstat (limited to 'servers/audio/effects/audio_effect_eq.h')
-rw-r--r--servers/audio/effects/audio_effect_eq.h48
1 files changed, 22 insertions, 26 deletions
diff --git a/servers/audio/effects/audio_effect_eq.h b/servers/audio/effects/audio_effect_eq.h
index 2f577ffd20..917bf584c7 100644
--- a/servers/audio/effects/audio_effect_eq.h
+++ b/servers/audio/effects/audio_effect_eq.h
@@ -29,72 +29,68 @@
#ifndef AUDIOEFFECTEQ_H
#define AUDIOEFFECTEQ_H
-
#include "servers/audio/audio_effect.h"
#include "servers/audio/effects/eq.h"
class AudioEffectEQ;
class AudioEffectEQInstance : public AudioEffectInstance {
- GDCLASS(AudioEffectEQInstance,AudioEffectInstance)
-friend class AudioEffectEQ;
+ GDCLASS(AudioEffectEQInstance, AudioEffectInstance)
+ friend class AudioEffectEQ;
Ref<AudioEffectEQ> base;
Vector<EQ::BandProcess> bands[2];
Vector<float> gains;
-public:
-
- virtual void process(const AudioFrame *p_src_frames,AudioFrame *p_dst_frames,int p_frame_count);
+public:
+ virtual void process(const AudioFrame *p_src_frames, AudioFrame *p_dst_frames, int p_frame_count);
};
-
class AudioEffectEQ : public AudioEffect {
- GDCLASS(AudioEffectEQ,AudioEffect)
+ GDCLASS(AudioEffectEQ, AudioEffect)
-friend class AudioEffectEQInstance;
+ friend class AudioEffectEQInstance;
EQ eq;
Vector<float> gain;
- Map<StringName,int> prop_band_map;
+ Map<StringName, int> prop_band_map;
Vector<String> band_names;
protected:
- bool _set(const StringName& p_name, const Variant& p_value);
- bool _get(const StringName& p_name,Variant &r_ret) const;
- void _get_property_list( List<PropertyInfo> *p_list) const;
-
-
+ bool _set(const StringName &p_name, const Variant &p_value);
+ bool _get(const StringName &p_name, Variant &r_ret) const;
+ void _get_property_list(List<PropertyInfo> *p_list) const;
static void _bind_methods();
-public:
-
+public:
Ref<AudioEffectInstance> instance();
- void set_band_gain_db(int p_band,float p_volume);
+ void set_band_gain_db(int p_band, float p_volume);
float get_band_gain_db(int p_band) const;
int get_band_count() const;
- AudioEffectEQ(EQ::Preset p_preset=EQ::PRESET_6_BANDS);
+ AudioEffectEQ(EQ::Preset p_preset = EQ::PRESET_6_BANDS);
};
-
class AudioEffectEQ6 : public AudioEffectEQ {
- GDCLASS(AudioEffectEQ6,AudioEffectEQ)
+ GDCLASS(AudioEffectEQ6, AudioEffectEQ)
public:
- AudioEffectEQ6() : AudioEffectEQ(EQ::PRESET_6_BANDS) {}
+ AudioEffectEQ6()
+ : AudioEffectEQ(EQ::PRESET_6_BANDS) {}
};
class AudioEffectEQ10 : public AudioEffectEQ {
- GDCLASS(AudioEffectEQ10,AudioEffectEQ)
+ GDCLASS(AudioEffectEQ10, AudioEffectEQ)
public:
- AudioEffectEQ10() : AudioEffectEQ(EQ::PRESET_10_BANDS) {}
+ AudioEffectEQ10()
+ : AudioEffectEQ(EQ::PRESET_10_BANDS) {}
};
class AudioEffectEQ21 : public AudioEffectEQ {
- GDCLASS(AudioEffectEQ21,AudioEffectEQ)
+ GDCLASS(AudioEffectEQ21, AudioEffectEQ)
public:
- AudioEffectEQ21() : AudioEffectEQ(EQ::PRESET_21_BANDS) {}
+ AudioEffectEQ21()
+ : AudioEffectEQ(EQ::PRESET_21_BANDS) {}
};
#endif // AUDIOEFFECTEQ_H