aboutsummaryrefslogtreecommitdiffstats
path: root/src/CrossFade.hxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-10-26 13:13:16 +0200
committerMax Kellermann <max@duempel.org>2013-10-26 13:53:32 +0200
commit067572c6dd44d0abde9bf34220ba2f45d0c120ca (patch)
tree41a5465055fee2e53702059c93d201e8ae2b6838 /src/CrossFade.hxx
parent7f03f68fcc430bee1f5586bf0b6f0f6a16956897 (diff)
downloadmpd-067572c6dd44d0abde9bf34220ba2f45d0c120ca.tar.gz
mpd-067572c6dd44d0abde9bf34220ba2f45d0c120ca.tar.xz
mpd-067572c6dd44d0abde9bf34220ba2f45d0c120ca.zip
CrossFade: reimplement mixramp_interpolate() without strtok()
Don't require a writable string, and don't modify it.
Diffstat (limited to 'src/CrossFade.hxx')
-rw-r--r--src/CrossFade.hxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/CrossFade.hxx b/src/CrossFade.hxx
index 3b9aa58cc..d30d06320 100644
--- a/src/CrossFade.hxx
+++ b/src/CrossFade.hxx
@@ -20,6 +20,8 @@
#ifndef MPD_CROSSFADE_HXX
#define MPD_CROSSFADE_HXX
+#include "Compiler.h"
+
struct AudioFormat;
struct music_chunk;
@@ -40,11 +42,12 @@ struct music_chunk;
* @return the number of chunks for crossfading, or 0 if cross fading
* should be disabled for this song change
*/
+gcc_pure
unsigned
cross_fade_calc(float duration, float total_time,
float mixramp_db, float mixramp_delay,
float replay_gain_db, float replay_gain_prev_db,
- char *mixramp_start, char *mixramp_prev_end,
+ const char *mixramp_start, const char *mixramp_prev_end,
AudioFormat af, AudioFormat old_format,
unsigned max_chunks);