Revision 5d6e4c16 libavcodec/flacdec.c

View differences:

libavcodec/flacdec.c
113 113
    FLACContext *s = avctx->priv_data;
114 114
    s->avctx = avctx;
115 115

  
116
    avctx->sample_fmt = SAMPLE_FMT_S16;
116
    avctx->sample_fmt = AV_SAMPLE_FMT_S16;
117 117

  
118 118
    /* for now, the raw FLAC header is allowed to be passed to the decoder as
119 119
       frame data instead of extradata. */
......
126 126
    /* initialize based on the demuxer-supplied streamdata header */
127 127
    ff_flac_parse_streaminfo(avctx, (FLACStreaminfo *)s, streaminfo);
128 128
    if (s->bps > 16)
129
        avctx->sample_fmt = SAMPLE_FMT_S32;
129
        avctx->sample_fmt = AV_SAMPLE_FMT_S32;
130 130
    else
131
        avctx->sample_fmt = SAMPLE_FMT_S16;
131
        avctx->sample_fmt = AV_SAMPLE_FMT_S16;
132 132
    allocate_buffers(s);
133 133
    s->got_streaminfo = 1;
134 134

  
......
603 603
    s->bps = s->avctx->bits_per_raw_sample = fi.bps;
604 604

  
605 605
    if (s->bps > 16) {
606
        s->avctx->sample_fmt = SAMPLE_FMT_S32;
606
        s->avctx->sample_fmt = AV_SAMPLE_FMT_S32;
607 607
        s->sample_shift = 32 - s->bps;
608 608
        s->is32 = 1;
609 609
    } else {
610
        s->avctx->sample_fmt = SAMPLE_FMT_S16;
610
        s->avctx->sample_fmt = AV_SAMPLE_FMT_S16;
611 611
        s->sample_shift = 16 - s->bps;
612 612
        s->is32 = 0;
613 613
    }

Also available in: Unified diff