diff options
author | Carl Eugen Hoyos <cehoyos@ag.or.at> | 2014-08-10 22:31:33 +0200 |
---|---|---|
committer | Carl Eugen Hoyos <cehoyos@ag.or.at> | 2014-08-10 22:31:33 +0200 |
commit | 788cf6f0c60739653a1ded8d1fd79a805a16d530 (patch) | |
tree | 256bb827e211eaf6cc57702527effb34562b5db8 /libavutil/frame.c | |
parent | 3539d6c63a16e1b2874bb037a86f317449c58770 (diff) | |
download | ffmpeg-788cf6f0c60739653a1ded8d1fd79a805a16d530.tar.gz |
Remove panscan information in av_frame_copy_props() if resolution changes.
Fixes ticket #3750.
Diffstat (limited to 'libavutil/frame.c')
-rw-r--r-- | libavutil/frame.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libavutil/frame.c b/libavutil/frame.c index 67a7d3e9e4..12eac5540b 100644 --- a/libavutil/frame.c +++ b/libavutil/frame.c @@ -492,7 +492,11 @@ int av_frame_copy_props(AVFrame *dst, const AVFrame *src) for (i = 0; i < src->nb_side_data; i++) { const AVFrameSideData *sd_src = src->side_data[i]; - AVFrameSideData *sd_dst = av_frame_new_side_data(dst, sd_src->type, + AVFrameSideData *sd_dst; + if ( sd_src->type == AV_FRAME_DATA_PANSCAN + && (src->width != dst->width || src->height != dst->height)) + continue; + sd_dst = av_frame_new_side_data(dst, sd_src->type, sd_src->size); if (!sd_dst) { for (i = 0; i < dst->nb_side_data; i++) { |