From 0a59be26d6e9862e3f853e855c7a3d78810735f268a6e3965ea93bb3be0bc2e1 Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Sun, 16 Jan 2022 15:54:50 +0000 Subject: [PATCH] Accepting request 946768 from home:gmbr3:Active - Add ffmpeg-chromium.patch: allows Chromium to use the now internalised field first_dts OBS-URL: https://build.opensuse.org/request/show/946768 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/ffmpeg-5?expand=0&rev=3 --- ffmpeg-5.changes | 6 ++++++ ffmpeg-5.spec | 1 + ffmpeg-chromium.patch | 41 +++++++++++++++++++++++++++++++++++++++++ 3 files changed, 48 insertions(+) create mode 100644 ffmpeg-chromium.patch diff --git a/ffmpeg-5.changes b/ffmpeg-5.changes index 5266211..756630b 100644 --- a/ffmpeg-5.changes +++ b/ffmpeg-5.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Sun Jan 16 12:09:57 UTC 2022 - Callum Farmer + +- Add ffmpeg-chromium.patch: allows Chromium to use the now + internalised field first_dts + ------------------------------------------------------------------- Fri Jan 14 23:16:18 UTC 2022 - Jan Engelhardt diff --git a/ffmpeg-5.spec b/ffmpeg-5.spec index 5cb703a..d8cc2fa 100644 --- a/ffmpeg-5.spec +++ b/ffmpeg-5.spec @@ -117,6 +117,7 @@ Patch3: ffmpeg-codec-choice.diff Patch4: ffmpeg-4.2-dlopen-fdk_aac.patch Patch8: vmaf-trim-usr-local.patch Patch9: ffmpeg-4.4-CVE-2020-22046.patch +Patch10: ffmpeg-chromium.patch BuildRequires: ladspa-devel BuildRequires: libgsm-devel BuildRequires: libmp3lame-devel diff --git a/ffmpeg-chromium.patch b/ffmpeg-chromium.patch new file mode 100644 index 0000000..932b63c --- /dev/null +++ b/ffmpeg-chromium.patch @@ -0,0 +1,41 @@ +commit 95aab0fd83619408995720ce53d7a74790580220 +author liberato@chromium.org Thu Jul 08 02:01:22 2021 +committer liberato@chromium.org Thu Jul 08 02:01:22 2021 +tree ac725b5e2c548c8142aa7096d8184d87d3876a49 +parent e073b7a22e4993e0a7cab80a42a21524e5349f95 + +Add av_stream_get_first_dts for Chromium + +diff --git a/libavformat/avformat.h b/libavformat/avformat.h +index cd7b0d9..b4a6dce 100644 +--- a/libavformat/avformat.h ++++ b/libavformat/avformat.h +@@ -1010,6 +1010,10 @@ + */ + int64_t av_stream_get_end_pts(const AVStream *st); + ++// Chromium: We use the internal field first_dts vvv ++int64_t av_stream_get_first_dts(const AVStream *st); ++// Chromium: We use the internal field first_dts ^^^ ++ + #define AV_PROGRAM_RUNNING 1 + + /** +diff --git a/libavformat/utils.c b/libavformat/utils.c +index de7580c..0ef0fe5 100644 +--- a/libavformat/utils.c ++++ b/libavformat/utils.c +@@ -121,6 +121,13 @@ + return AV_NOPTS_VALUE; + } + ++// Chromium: We use the internal field first_dts vvv ++int64_t av_stream_get_first_dts(const AVStream *st) ++{ ++ return cffstream(st)->first_dts; ++} ++// Chromium: We use the internal field first_dts ^^^ ++ + struct AVCodecParserContext *av_stream_get_parser(const AVStream *st) + { + return cffstream(st)->parser;