Commit fb726ef0 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/dpx: fix reading of the packing field

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 8cb7d205
...@@ -125,9 +125,9 @@ static int decode_frame(AVCodecContext *avctx, ...@@ -125,9 +125,9 @@ static int decode_frame(AVCodecContext *avctx,
avctx->bits_per_raw_sample = avctx->bits_per_raw_sample =
bits_per_color = buf[0]; bits_per_color = buf[0];
buf++; buf++;
packing = *((uint16_t*)buf); packing = read16(&buf, endian);
buf += 824; buf += 822;
avctx->sample_aspect_ratio.num = read32(&buf, endian); avctx->sample_aspect_ratio.num = read32(&buf, endian);
avctx->sample_aspect_ratio.den = read32(&buf, endian); avctx->sample_aspect_ratio.den = read32(&buf, endian);
if (avctx->sample_aspect_ratio.num > 0 && avctx->sample_aspect_ratio.den > 0) if (avctx->sample_aspect_ratio.num > 0 && avctx->sample_aspect_ratio.den > 0)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment