aboutsummaryrefslogtreecommitdiffstats
path: root/src/DecoderControl.hxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-10-26 14:19:34 +0200
committerMax Kellermann <max@duempel.org>2013-10-26 14:19:34 +0200
commit85ae7e9c9a8e31359834b3b4da3c358b941e8012 (patch)
treecadafa466a385107ba43f4c60664a064c7617550 /src/DecoderControl.hxx
parent2098b94b47a60f6265dd5afb61757e9f6b7f9a6e (diff)
downloadmpd-85ae7e9c9a8e31359834b3b4da3c358b941e8012.tar.gz
mpd-85ae7e9c9a8e31359834b3b4da3c358b941e8012.tar.xz
mpd-85ae7e9c9a8e31359834b3b4da3c358b941e8012.zip
DecoderControl: move code/attributes to new class MixRampInfo
Diffstat (limited to 'src/DecoderControl.hxx')
-rw-r--r--src/DecoderControl.hxx17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/DecoderControl.hxx b/src/DecoderControl.hxx
index c27177cbd..9a949b2fe 100644
--- a/src/DecoderControl.hxx
+++ b/src/DecoderControl.hxx
@@ -22,6 +22,7 @@
#include "DecoderCommand.hxx"
#include "AudioFormat.hxx"
+#include "MixRampInfo.hxx"
#include "thread/Mutex.hxx"
#include "thread/Cond.hxx"
#include "thread/Thread.hxx"
@@ -139,9 +140,8 @@ struct decoder_control {
float replay_gain_db;
float replay_gain_prev_db;
- char *mixramp_start;
- char *mixramp_end;
- char *mixramp_prev_end;
+
+ MixRampInfo mix_ramp, previous_mix_ramp;
decoder_control();
~decoder_control();
@@ -351,19 +351,20 @@ public:
void Quit();
const char *GetMixRampStart() const {
- return mixramp_start;
+ return mix_ramp.GetStart();
}
const char *GetMixRampEnd() const {
- return mixramp_end;
+ return mix_ramp.GetEnd();
}
const char *GetMixRampPreviousEnd() const {
- return mixramp_prev_end;
+ return previous_mix_ramp.GetEnd();
}
- void MixRampStart(char *_mixramp_start);
- void MixRampEnd(char *_mixramp_end);
+ void SetMixRamp(MixRampInfo &&new_value) {
+ mix_ramp = std::move(new_value);
+ }
/**
* Move mixramp_end to mixramp_prev_end and clear