diff options
Diffstat (limited to 'libavcodec/atrac1.c')
-rw-r--r-- | libavcodec/atrac1.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/libavcodec/atrac1.c b/libavcodec/atrac1.c index 6159954966..5ff8816476 100644 --- a/libavcodec/atrac1.c +++ b/libavcodec/atrac1.c @@ -305,20 +305,15 @@ static int atrac1_decode_frame(AVCodecContext *avctx, void *data, at1_subband_synthesis(q, su, q->out_samples[ch]); } - /* round, convert to 16bit and interleave */ + /* interleave; FIXME, should create/use a DSP function */ if (q->channels == 1) { /* mono */ - q->dsp.vector_clipf(samples, q->out_samples[0], -32700.0 / (1 << 15), - 32700.0 / (1 << 15), AT1_SU_SAMPLES); + memcpy(samples, q->out_samples[0], AT1_SU_SAMPLES * 4); } else { /* stereo */ for (i = 0; i < AT1_SU_SAMPLES; i++) { - samples[i * 2] = av_clipf(q->out_samples[0][i], - -32700.0 / (1 << 15), - 32700.0 / (1 << 15)); - samples[i * 2 + 1] = av_clipf(q->out_samples[1][i], - -32700.0 / (1 << 15), - 32700.0 / (1 << 15)); + samples[i * 2] = q->out_samples[0][i]; + samples[i * 2 + 1] = q->out_samples[1][i]; } } |