~ubuntu-branches/ubuntu/utopic/libav/utopic

« back to all changes in this revision

Viewing changes to libavcodec/nellymoserdec.c

  • Committer: Package Import Robot
  • Author(s): Reinhard Tartler
  • Date: 2012-12-21 15:32:13 UTC
  • mto: (1.2.18)
  • mto: This revision was merged to the branch mainline in revision 34.
  • Revision ID: package-import@ubuntu.com-20121221153213-fudzrugjzivtv0wp
Tags: upstream-9~beta3
ImportĀ upstreamĀ versionĀ 9~beta3

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
 * implementors. The original code is available from http://code.google.com/p/nelly2pcm/
32
32
 */
33
33
 
34
 
#include "nellymoser.h"
 
34
#include "libavutil/channel_layout.h"
35
35
#include "libavutil/lfg.h"
36
36
#include "libavutil/random_seed.h"
37
 
#include "libavutil/audioconvert.h"
38
37
#include "avcodec.h"
39
38
#include "dsputil.h"
40
39
#include "fft.h"
41
40
#include "fmtconvert.h"
 
41
#include "internal.h"
 
42
#include "nellymoser.h"
42
43
#include "sinewin.h"
43
44
 
44
45
#define BITSTREAM_READER_LE
129
130
    if (!ff_sine_128[127])
130
131
        ff_init_ff_sine_windows(7);
131
132
 
 
133
    avctx->channels       = 1;
132
134
    avctx->channel_layout = AV_CH_LAYOUT_MONO;
133
135
 
134
136
    avcodec_get_frame_defaults(&s->frame);
165
167
 
166
168
    /* get output buffer */
167
169
    s->frame.nb_samples = NELLY_SAMPLES * blocks;
168
 
    if ((ret = avctx->get_buffer(avctx, &s->frame)) < 0) {
 
170
    if ((ret = ff_get_buffer(avctx, &s->frame)) < 0) {
169
171
        av_log(avctx, AV_LOG_ERROR, "get_buffer() failed\n");
170
172
        return ret;
171
173
    }