~ppsspp/ppsspp/ffmpeg

« back to all changes in this revision

Viewing changes to libavcodec/cook.c

  • Committer: Henrik Rydgård
  • Date: 2014-01-03 10:44:32 UTC
  • Revision ID: git-v1:87c6c126784b1718bfa448ecf2e6a9fef781eb4e
Update our ffmpeg snapshot to a clone of the official repository.

This is because Maxim's at3plus support has been officially merged!

Show diffs side-by-side

added added

removed removed

Lines of Context:
51
51
#include "fft.h"
52
52
#include "internal.h"
53
53
#include "sinewin.h"
 
54
#include "unary.h"
54
55
 
55
56
#include "cookdata.h"
56
57
 
228
229
 
229
230
    /* Initialize the MDCT. */
230
231
    if ((ret = ff_mdct_init(&q->mdct_ctx, av_log2(mlt_size) + 1, 1, 1.0 / 32768.0))) {
231
 
        av_free(q->mlt_window);
 
232
        av_freep(&q->mlt_window);
232
233
        return ret;
233
234
    }
234
235
    av_log(q->avctx, AV_LOG_DEBUG, "MDCT initialized, order = %d.\n",
302
303
    av_log(avctx, AV_LOG_DEBUG, "Deallocating memory.\n");
303
304
 
304
305
    /* Free allocated memory buffers. */
305
 
    av_free(q->mlt_window);
306
 
    av_free(q->decoded_bytes_buffer);
 
306
    av_freep(&q->mlt_window);
 
307
    av_freep(&q->decoded_bytes_buffer);
307
308
 
308
309
    /* Free the transform. */
309
310
    ff_mdct_end(&q->mdct_ctx);
331
332
{
332
333
    int i, n;
333
334
 
334
 
    while (get_bits1(gb)) {
335
 
        /* NOTHING */
336
 
    }
337
 
 
338
 
    n = get_bits_count(gb) - 1;     // amount of elements*2 to update
 
335
    n = get_unary(gb, 0, get_bits_left(gb));     // amount of elements*2 to update
339
336
 
340
337
    i = 0;
341
338
    while (n--) {