summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-03-19 23:56:31 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-03-19 23:56:31 +0100
commit77bd35d76db66426648ed4080f91123bc306a3ef (patch)
treea82e3f2b6c1d08e4284b0e33839acdac7022b89d
parentd3bd943108d321b387f955f3ab1ece4e9977401f (diff)
avcodec/dnxhddec: reset cur_field for non interlaced frames
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavcodec/dnxhddec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c
index 2b0e2de0a0..cc011c408d 100644
--- a/libavcodec/dnxhddec.c
+++ b/libavcodec/dnxhddec.c
@@ -136,6 +136,8 @@ static int dnxhd_decode_header(DNXHDContext *ctx, AVFrame *frame,
frame->top_field_first = first_field ^ ctx->cur_field;
av_log(ctx->avctx, AV_LOG_DEBUG,
"interlaced %d, cur field %d\n", buf[5] & 3, ctx->cur_field);
+ } else {
+ ctx->cur_field = 0;
}
ctx->height = AV_RB16(buf + 0x18);