aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTakamichi Horikawa <takamichiho@gmail.com>2017-07-11 23:22:26 +0900
committerTakamichi Horikawa <takamichiho@gmail.com>2017-07-11 23:22:26 +0900
commitf0c957012f65775976be05d2497a6a30c222b7e6 (patch)
treefa3fd28a898d8f9252dbd4fabe10ecc6de8b221f
parentc8544a0a1b20fb3bb0b6d5a1ee2df2e4b133efa9 (diff)
fixed fft
-rw-r--r--fft/fft.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fft/fft.c b/fft/fft.c
index 69c0971..7cb5374 100644
--- a/fft/fft.c
+++ b/fft/fft.c
@@ -4,7 +4,7 @@
void fft_write(struct fmplayer_fft_data *data, const int16_t *buf, unsigned len) {
if (len > FFTLEN) {
- unsigned discard = FFTLEN - len;
+ unsigned discard = len - FFTLEN;
buf += discard*2;
len = FFTLEN;
}