diff options
author | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2007-08-04 12:59:49 +0000 |
---|---|---|
committer | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2007-08-04 12:59:49 +0000 |
commit | 035bc6470d4c6edecdf3b217ce58e80a4979d831 (patch) | |
tree | c83caae40d2f5d98c60dd9582c1d20f37d648f70 /libavcodec/dnxhddec.c | |
parent | 36ebf912064da70abdb63de2f364e16dfd43e5bb (diff) | |
download | ffmpeg-035bc6470d4c6edecdf3b217ce58e80a4979d831.tar.gz |
add coding unit size for interlaced decoding
Originally committed as revision 9897 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/dnxhddec.c')
-rw-r--r-- | libavcodec/dnxhddec.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c index d32a6dd169..e60b3e3f0c 100644 --- a/libavcodec/dnxhddec.c +++ b/libavcodec/dnxhddec.c @@ -33,6 +33,7 @@ typedef struct { unsigned int width, height; int interlaced; unsigned int frame_size; + unsigned int coding_unit_size; int index_bits; int bit_depth; const uint8_t *luma_weigth, *chroma_weigth; @@ -66,13 +67,13 @@ typedef struct { } DNXHDContext; static const CIDEntry cid_table[] = { - { 1238, 1920, 1080, 0, 917504, 4, 8, + { 1238, 1920, 1080, 0, 917504, 917504, 4, 8, dnxhd_1238_luma_weigth, dnxhd_1238_chroma_weigth, dnxhd_1238_dc_codes, dnxhd_1238_dc_bits, dnxhd_1238_ac_codes, dnxhd_1238_ac_bits, dnxhd_1238_ac_level, dnxhd_1238_ac_run_flag, dnxhd_1238_ac_index_flag, dnxhd_1238_run_codes, dnxhd_1238_run_bits, dnxhd_1238_run }, -/* { 1243, 1920, 1080, 1, 917504, 4, 8, */ +/* { 1243, 1920, 1080, 1, 917504, 458752, 4, 8, */ /* dnxhd_1243_luma_weigth, dnxhd_1243_chroma_weigth, */ /* dnxhd_1238_dc_codes, dnxhd_1238_dc_bits, */ /* dnxhd_1238_ac_codes, dnxhd_1238_ac_bits, dnxhd_1238_ac_level, */ @@ -170,7 +171,7 @@ static int dnxhd_decode_header(DNXHDContext *ctx, uint8_t *buf, int buf_size) if (dnxhd_init_vlc(ctx, ctx->cid) < 0) return -1; - if (buf_size < ctx->cid_table->frame_size) { + if (buf_size < ctx->cid_table->coding_unit_size) { av_log(ctx->avctx, AV_LOG_ERROR, "incorrect frame size\n"); return -1; } |