From 6505e8cfd02b9112e24bb40c145d6c760f15d622 Mon Sep 17 00:00:00 2001 From: James Almer Date: Mon, 8 May 2017 15:46:23 -0300 Subject: avcodec/h264dec: be more explicit in handling container cropping This merges commit 4fded0480f20f4d7ca5e776a85574de34dfead14 from libav, originally written by Anton Khirnov and skipped in fc63d5ceb357c4b760cb02772de0b50d0557140f. libavcodec/h264_slice.c | 20 +++++++++++++------- libavcodec/h264dec.c | 3 +++ libavcodec/h264dec.h | 5 +++++ 3 files changed, 21 insertions(+), 7 deletions(-) --- libavcodec/h264dec.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'libavcodec/h264dec.h') diff --git a/libavcodec/h264dec.h b/libavcodec/h264dec.h index 1c0dfbf7f7..5e03d55558 100644 --- a/libavcodec/h264dec.h +++ b/libavcodec/h264dec.h @@ -534,6 +534,11 @@ typedef struct H264Context { int cur_bit_depth_luma; int16_t slice_row[MAX_SLICES]; ///< to detect when MAX_SLICES is too low + /* original AVCodecContext dimensions, used to handle container + * cropping */ + int width_from_caller; + int height_from_caller; + int enable_er; H264SEIContext sei; -- cgit v1.2.3