aboutsummaryrefslogtreecommitdiff
path: root/libavformat/avidec.c
diff options
context:
space:
mode:
authorMarton Balint2019-08-24 01:39:33 +0200
committerMarton Balint2019-09-02 22:06:00 +0200
commitb4e910370992d4e40af1f62ec0a6a59867dac2ed (patch)
tree436c115bfd5332030488b42905579103160828b4 /libavformat/avidec.c
parent3a17fe2bdd57294edda378693ff45f19cbdaf0ed (diff)
avformat/avidec: add support for recognizing HEVC fourcc when demuxing
Some security cams generate this, as well as some versions of VirtualDub and VLC so support for _reading_ such files is justified. Fixes ticket #7110. See also this discussion: https://patchwork.ffmpeg.org/patch/8744/ Signed-off-by: Marton Balint <cus@passwd.hu> (cherry picked from commit 2e31774b409d77f046f166fb3ff630a9ef91def7)
Diffstat (limited to 'libavformat/avidec.c')
-rw-r--r--libavformat/avidec.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavformat/avidec.c b/libavformat/avidec.c
index 1d887b1cc9..df78925d55 100644
--- a/libavformat/avidec.c
+++ b/libavformat/avidec.c
@@ -815,6 +815,9 @@ FF_ENABLE_DEPRECATION_WARNINGS
"mov tag found in avi (fourcc %s)\n",
av_fourcc2str(tag1));
}
+ if (!st->codecpar->codec_id)
+ st->codecpar->codec_id = ff_codec_get_id(ff_codec_bmp_tags_unofficial, tag1);
+
/* This is needed to get the pict type which is necessary
* for generating correct pts. */
st->need_parsing = AVSTREAM_PARSE_HEADERS;