Revision ec0350c9 libavcodec/ac3dec.c

View differences:

libavcodec/ac3dec.c
33 33
#include <string.h>
34 34

  
35 35
#include "libavutil/crc.h"
36
#include "libavutil/random.h"
37 36
#include "avcodec.h"
38 37
#include "ac3_parser.h"
39 38
#include "bitstream.h"
......
198 197
    ff_mdct_init(&s->imdct_512, 9, 1);
199 198
    ff_kbd_window_init(s->window, 5.0, 256);
200 199
    dsputil_init(&s->dsp, avctx);
201
    av_init_random(0, &s->dith_state);
200
    av_lfg_init(&s->dith_state, 0);
202 201

  
203 202
    /* set bias values for float to int16 conversion */
204 203
    if(s->dsp.float_to_int16_interleave == ff_float_to_int16_interleave_c) {
......
450 449
        tbap = bap[i];
451 450
        switch (tbap) {
452 451
            case 0:
453
                coeffs[i] = (av_random(&s->dith_state) & 0x7FFFFF) - 0x400000;
452
                coeffs[i] = (av_lfg_get(&s->dith_state) & 0x7FFFFF) - 0x400000;
454 453
                break;
455 454

  
456 455
            case 1:

Also available in: Unified diff