diff --git a/packages/multimedia/ffmpeg/patches/ffmpeg-99.1004-added_upstream_mvc_patches.patch b/packages/multimedia/ffmpeg/patches/ffmpeg-99.1004-added_upstream_mvc_patches.patch index 981a88e102..551a27104a 100644 --- a/packages/multimedia/ffmpeg/patches/ffmpeg-99.1004-added_upstream_mvc_patches.patch +++ b/packages/multimedia/ffmpeg/patches/ffmpeg-99.1004-added_upstream_mvc_patches.patch @@ -1,7 +1,7 @@ From 20af7af23a9f366476e67669f14957dfaf58f141 Mon Sep 17 00:00:00 2001 From: Hendrik Leppkes Date: Sat, 9 Jan 2016 16:34:09 +0100 -Subject: [PATCH 1/3] avcodec: add h264_mvc codec id and profiles +Subject: [PATCH 1/4] avcodec: add h264_mvc codec id and profiles --- libavcodec/avcodec.h | 3 +++ @@ -75,13 +75,13 @@ index 37a6aa8bff..52c5b659c4 100644 { 0x24, AVMEDIA_TYPE_VIDEO, AV_CODEC_ID_HEVC }, { 0x42, AVMEDIA_TYPE_VIDEO, AV_CODEC_ID_CAVS }, -- -2.14.1 +2.17.0 From 0f3fda4e348e6b12570f5d279713f6da46511846 Mon Sep 17 00:00:00 2001 From: Hendrik Leppkes Date: Sat, 9 Jan 2016 16:34:40 +0100 -Subject: [PATCH 2/3] h264_parser: add support for parsing h264 mvc NALUs +Subject: [PATCH 2/4] h264_parser: add support for parsing h264 mvc NALUs --- libavcodec/h264.h | 2 ++ @@ -192,13 +192,13 @@ index f43b197d5e..f96e005ef3 100644 extern AVCodecParser ff_mjpeg_parser; extern AVCodecParser ff_mlp_parser; -- -2.14.1 +2.17.0 From cdd668dc436b9c78dcb31df477e329492356e7ec Mon Sep 17 00:00:00 2001 From: Hendrik Leppkes Date: Tue, 28 Nov 2017 16:12:12 +0000 -Subject: [PATCH 3/3] h264_parser: force grabing a new timestamp until a frame +Subject: [PATCH 3/4] h264_parser: force grabing a new timestamp until a frame start was found --- @@ -220,5 +220,65 @@ index be8b9db9b0..81c9a1bbae 100644 *poutbuf = NULL; *poutbuf_size = 0; -- -2.14.1 +2.17.0 + + +From fb0ec9a132d6eb8fd74348ef87b1176c7ca34a00 Mon Sep 17 00:00:00 2001 +From: popcornmix +Date: Mon, 28 May 2018 13:35:36 +0100 +Subject: [PATCH 4/4] fixup + +--- + libavcodec/extract_extradata_bsf.c | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +diff --git a/libavcodec/extract_extradata_bsf.c b/libavcodec/extract_extradata_bsf.c +index 082b3e749b..7612749efc 100644 +--- a/libavcodec/extract_extradata_bsf.c ++++ b/libavcodec/extract_extradata_bsf.c +@@ -59,7 +59,7 @@ static int extract_extradata_h2645(AVBSFContext *ctx, AVPacket *pkt, + HEVC_NAL_VPS, HEVC_NAL_SPS, HEVC_NAL_PPS, + }; + static const int extradata_nal_types_h264[] = { +- H264_NAL_SPS, H264_NAL_PPS, ++ H264_NAL_SPS, H264_NAL_SPS_SUBSET, H264_NAL_PPS, + }; + + ExtractExtradataContext *s = ctx->priv_data; +@@ -90,7 +90,7 @@ static int extract_extradata_h2645(AVBSFContext *ctx, AVPacket *pkt, + if (nal->type == HEVC_NAL_SPS) has_sps = 1; + if (nal->type == HEVC_NAL_VPS) has_vps = 1; + } else { +- if (nal->type == H264_NAL_SPS) has_sps = 1; ++ if (nal->type == H264_NAL_SPS || nal->type == H264_NAL_SPS_SUBSET) has_sps = 1; + } + } else if (s->remove) { + filtered_size += nal->raw_size + 3; +@@ -99,7 +99,7 @@ static int extract_extradata_h2645(AVBSFContext *ctx, AVPacket *pkt, + + if (extradata_size && + ((ctx->par_in->codec_id == AV_CODEC_ID_HEVC && has_sps && has_vps) || +- (ctx->par_in->codec_id == AV_CODEC_ID_H264 && has_sps))) { ++ ((ctx->par_in->codec_id == AV_CODEC_ID_H264 || ctx->par_in->codec_id == AV_CODEC_ID_H264_MVC) && has_sps))) { + AVBufferRef *filtered_buf; + uint8_t *extradata, *filtered_data; + +@@ -253,6 +253,7 @@ static const struct { + } extract_tab[] = { + { AV_CODEC_ID_CAVS, extract_extradata_mpeg4 }, + { AV_CODEC_ID_H264, extract_extradata_h2645 }, ++ { AV_CODEC_ID_H264_MVC, extract_extradata_h2645 }, + { AV_CODEC_ID_HEVC, extract_extradata_h2645 }, + { AV_CODEC_ID_MPEG1VIDEO, extract_extradata_mpeg12 }, + { AV_CODEC_ID_MPEG2VIDEO, extract_extradata_mpeg12 }, +@@ -317,6 +318,7 @@ static void extract_extradata_close(AVBSFContext *ctx) + static const enum AVCodecID codec_ids[] = { + AV_CODEC_ID_CAVS, + AV_CODEC_ID_H264, ++ AV_CODEC_ID_H264_MVC, + AV_CODEC_ID_HEVC, + AV_CODEC_ID_MPEG1VIDEO, + AV_CODEC_ID_MPEG2VIDEO, +-- +2.17.0