Browse Source

- ffmpeg: bump version to 4.3.2

master
vanhofen 4 years ago
parent
commit
75a53770f0
  1. 505
      make/target-ffmpeg.mk
  2. 97
      package/ffmpeg/patches/0001-libavutil-include-assembly-with-full-path-from-sourc.patch
  3. 2
      package/ffmpeg/patches/4_02_fix_mpegts.patch
  4. 8
      package/ffmpeg/patches/4_03_allow_to_choose_rtmp_impl_at_runtime.patch
  5. 2
      package/ffmpeg/patches/4_04_hls_replace_key_uri.patch
  6. 10
      package/ffmpeg/patches/4_06_optimize_aac.patch
  7. 71
      package/ffmpeg/patches/4_07_increase_buffer_size.patch
  8. 2
      package/ffmpeg/patches/4_08_recheck_discard_flags.patch
  9. 0
      package/ffmpeg/patches/4_11_rtsp.patch
  10. 0
      package/ffmpeg/patches/4_12_dxva2.patch
  11. 14
      package/ffmpeg/patches/4_A02-corrupt-h264-frames.patch
  12. 78
      package/ffmpeg/patches/4_A11-FFmpeg-devel-amfenc-Add-support-for-pict_type-field.patch
  13. 2
      package/ffmpeg/patches/4_mips64_cpu_detection.patch

505
make/target-ffmpeg.mk

@ -3,7 +3,7 @@
#
# -----------------------------------------------------------------------------
FFMPEG_VERSION = 4.3.1
FFMPEG_VERSION = 4.3.2
FFMPEG_DIR = ffmpeg-$(FFMPEG_VERSION)
FFMPEG_SOURCE = ffmpeg-$(FFMPEG_VERSION).tar.xz
FFMPEG_SITE = http://www.ffmpeg.org/releases
@ -11,14 +11,12 @@ FFMPEG_SITE = http://www.ffmpeg.org/releases
$(DL_DIR)/$(FFMPEG_SOURCE):
$(download) $(FFMPEG_SITE)/$(FFMPEG_SOURCE)
FFMPEG_DEPENDENCIES = openssl freetype rtmpdump libbluray libass libxml2 alsa-lib
FFMPEG_DEPENDENCIES = openssl zlib bzip2 freetype rtmpdump libass libxml2 alsa-lib
FFMPEG_UNPATCHED := no
FFMPEG_CONF_OPTS = \
--prefix=$(prefix) \
--cross-prefix=$(TARGET_CROSS) \
--datadir=$(REMOVE_datadir) \
--disable-ffprobe \
\
--disable-doc \
--disable-htmlpages \
@ -26,8 +24,6 @@ FFMPEG_CONF_OPTS = \
--disable-podpages \
--disable-txtpages \
\
--enable-ffprobe \
\
--disable-altivec \
--disable-amd3dnow \
--disable-amd3dnowext \
@ -56,244 +52,243 @@ FFMPEG_CONF_OPTS = \
--disable-vaapi \
--disable-vdpau \
\
--disable-parsers \
--enable-parser=aac \
--enable-parser=aac_latm \
--enable-parser=ac3 \
--enable-parser=dca \
--enable-parser=dvbsub \
--enable-parser=dvd_nav \
--enable-parser=dvdsub \
--enable-parser=flac \
--enable-parser=h264 \
--enable-parser=hevc \
--enable-parser=mjpeg \
--enable-parser=mpeg4video \
--enable-parser=mpegaudio \
--enable-parser=mpegvideo \
--enable-parser=png \
--enable-parser=vc1 \
--enable-parser=vorbis \
--enable-parser=vp8 \
--enable-parser=vp9 \
--disable-muxers \
--enable-muxer=apng \
--enable-muxer=flac \
--enable-muxer=h261 \
--enable-muxer=h263 \
--enable-muxer=h264 \
--enable-muxer=hevc \
--enable-muxer=image2 \
--enable-muxer=image2pipe \
--enable-muxer=m4v \
--enable-muxer=matroska \
--enable-muxer=mjpeg \
--enable-muxer=mp3 \
--enable-muxer=mp4 \
--enable-muxer=mpeg1video \
--enable-muxer=mpeg2video \
--enable-muxer=mpegts \
--enable-muxer=ogg \
\
--disable-decoders \
--enable-decoder=aac \
--enable-decoder=aac_latm \
--enable-decoder=adpcm_ct \
--enable-decoder=adpcm_g722 \
--enable-decoder=adpcm_g726 \
--enable-decoder=adpcm_g726le \
--enable-decoder=adpcm_ima_amv \
--enable-decoder=adpcm_ima_oki \
--enable-decoder=adpcm_ima_qt \
--enable-decoder=adpcm_ima_rad \
--enable-decoder=adpcm_ima_wav \
--enable-decoder=adpcm_ms \
--enable-decoder=adpcm_sbpro_2 \
--enable-decoder=adpcm_sbpro_3 \
--enable-decoder=adpcm_sbpro_4 \
--enable-decoder=adpcm_swf \
--enable-decoder=adpcm_yamaha \
--enable-decoder=alac \
--enable-decoder=ape \
--enable-decoder=ass \
--enable-decoder=atrac1 \
--enable-decoder=atrac3 \
--enable-decoder=atrac3p \
--enable-decoder=cook \
--enable-decoder=dca \
--enable-decoder=dsd_lsbf \
--enable-decoder=dsd_lsbf_planar \
--enable-decoder=dsd_msbf \
--enable-decoder=dsd_msbf_planar \
--enable-decoder=dvbsub \
--enable-decoder=dvdsub \
--enable-decoder=eac3 \
--enable-decoder=evrc \
--enable-decoder=flac \
--enable-decoder=flv \
--enable-decoder=g723_1 \
--enable-decoder=g729 \
--enable-decoder=gif \
--enable-decoder=h261 \
--enable-decoder=h263 \
--enable-decoder=h263i \
--enable-decoder=h264 \
--enable-decoder=hevc \
--enable-decoder=iac \
--enable-decoder=imc \
--enable-decoder=jpeg2000 \
--enable-decoder=jpegls \
--enable-decoder=mace3 \
--enable-decoder=mace6 \
--enable-decoder=metasound \
--enable-decoder=mjpeg \
--enable-decoder=mlp \
--enable-decoder=movtext \
--enable-decoder=mp1 \
--enable-decoder=mp3 \
--enable-decoder=mp3adu \
--enable-decoder=mp3adufloat \
--enable-decoder=mp3float \
--enable-decoder=mp3on4 \
--enable-decoder=mp3on4float \
--enable-decoder=mpeg1video \
--enable-decoder=mpeg2video \
--enable-decoder=mpeg4 \
--enable-decoder=nellymoser \
--enable-decoder=opus \
--enable-decoder=pcm_alaw \
--enable-decoder=pcm_bluray \
--enable-decoder=pcm_dvd \
--enable-decoder=pcm_f32be \
--enable-decoder=pcm_f32le \
--enable-decoder=pcm_f64be \
--enable-decoder=pcm_f64le \
--enable-decoder=pcm_lxf \
--enable-decoder=pcm_mulaw \
--enable-decoder=pcm_s16be \
--enable-decoder=pcm_s16be_planar \
--enable-decoder=pcm_s16le \
--enable-decoder=pcm_s16le_planar \
--enable-decoder=pcm_s24be \
--enable-decoder=pcm_s24daud \
--enable-decoder=pcm_s24le \
--enable-decoder=pcm_s24le_planar \
--enable-decoder=pcm_s32be \
--enable-decoder=pcm_s32le \
--enable-decoder=pcm_s32le_planar \
--enable-decoder=pcm_s8 \
--enable-decoder=pcm_s8_planar \
--enable-decoder=pcm_u16be \
--enable-decoder=pcm_u16le \
--enable-decoder=pcm_u24be \
--enable-decoder=pcm_u24le \
--enable-decoder=pcm_u32be \
--enable-decoder=pcm_u32le \
--enable-decoder=pcm_u8 \
--enable-decoder=pcm_zork \
--enable-decoder=pgssub \
--enable-decoder=png \
--enable-decoder=qcelp \
--enable-decoder=qdm2 \
--enable-decoder=ra_144 \
--enable-decoder=ra_288 \
--enable-decoder=ralf \
--enable-decoder=s302m \
--enable-decoder=shorten \
--enable-decoder=sipr \
--enable-decoder=sonic \
--enable-decoder=srt \
--enable-decoder=ssa \
--enable-decoder=subrip \
--enable-decoder=subviewer \
--enable-decoder=subviewer1 \
--enable-decoder=tak \
--enable-decoder=text \
--enable-decoder=truehd \
--enable-decoder=truespeech \
--enable-decoder=tta \
--enable-decoder=vorbis \
--enable-decoder=wavpack \
--enable-decoder=wmalossless \
--enable-decoder=wmapro \
--enable-decoder=wmav1 \
--enable-decoder=wmav2 \
--enable-decoder=wmavoice \
--enable-decoder=xsub \
--disable-parsers \
--enable-parser=aac \
--enable-parser=aac_latm \
--enable-parser=ac3 \
--enable-parser=dca \
--enable-parser=dvbsub \
--enable-parser=dvd_nav \
--enable-parser=dvdsub \
--enable-parser=flac \
--enable-parser=h264 \
--enable-parser=hevc \
--enable-parser=mjpeg \
--enable-parser=mpeg4video \
--enable-parser=mpegaudio \
--enable-parser=mpegvideo \
--enable-parser=png \
--enable-parser=vc1 \
--enable-parser=vorbis \
--enable-parser=vp8 \
--enable-parser=vp9 \
\
--disable-encoders \
--enable-encoder=aac \
--enable-encoder=h261 \
--enable-encoder=h263 \
--enable-encoder=h263p \
--enable-encoder=jpeg2000 \
--enable-encoder=jpegls \
--enable-encoder=ljpeg \
--enable-encoder=mjpeg \
--enable-encoder=mpeg1video \
--enable-encoder=mpeg2video \
--enable-encoder=mpeg4 \
--enable-encoder=png \
--enable-encoder=rawvideo \
--enable-encoder=aac \
--enable-encoder=h261 \
--enable-encoder=h263 \
--enable-encoder=h263p \
--enable-encoder=jpeg2000 \
--enable-encoder=jpegls \
--enable-encoder=ljpeg \
--enable-encoder=mjpeg \
--enable-encoder=mpeg1video \
--enable-encoder=mpeg2video \
--enable-encoder=mpeg4 \
--enable-encoder=png \
--enable-encoder=rawvideo \
\
--disable-demuxers \
--enable-demuxer=aac \
--enable-demuxer=ac3 \
--enable-demuxer=apng \
--enable-demuxer=ass \
--enable-demuxer=avi \
--enable-demuxer=dash \
--enable-demuxer=dts \
--enable-demuxer=ffmetadata \
--enable-demuxer=flac \
--enable-demuxer=flv \
--enable-demuxer=gif \
--enable-demuxer=h264 \
--enable-demuxer=hls \
--enable-demuxer=live_flv \
--enable-demuxer=image_bmp_pipe \
--enable-demuxer=image_jpeg_pipe \
--enable-demuxer=image_jpegls_pipe \
--enable-demuxer=image_png_pipe \
--enable-demuxer=image2 \
--enable-demuxer=image2pipe \
--enable-demuxer=m4v \
--enable-demuxer=matroska \
--enable-demuxer=mjpeg \
--enable-demuxer=mov \
--enable-demuxer=mp3 \
--enable-demuxer=mpegps \
--enable-demuxer=mpegts \
--enable-demuxer=mpegtsraw \
--enable-demuxer=mpegvideo \
--enable-demuxer=mpjpeg \
--enable-demuxer=ogg \
--enable-demuxer=pcm_s16be \
--enable-demuxer=pcm_s16le \
--enable-demuxer=rawvideo \
--enable-demuxer=realtext \
--enable-demuxer=rm \
--enable-demuxer=rtp \
--enable-demuxer=rtsp \
--enable-demuxer=srt \
--enable-demuxer=vc1 \
--enable-demuxer=wav \
--enable-demuxer=webm_dash_manifest \
--disable-decoders \
--enable-decoder=aac \
--enable-decoder=aac_latm \
--enable-decoder=adpcm_ct \
--enable-decoder=adpcm_g722 \
--enable-decoder=adpcm_g726 \
--enable-decoder=adpcm_g726le \
--enable-decoder=adpcm_ima_amv \
--enable-decoder=adpcm_ima_oki \
--enable-decoder=adpcm_ima_qt \
--enable-decoder=adpcm_ima_rad \
--enable-decoder=adpcm_ima_wav \
--enable-decoder=adpcm_ms \
--enable-decoder=adpcm_sbpro_2 \
--enable-decoder=adpcm_sbpro_3 \
--enable-decoder=adpcm_sbpro_4 \
--enable-decoder=adpcm_swf \
--enable-decoder=adpcm_yamaha \
--enable-decoder=alac \
--enable-decoder=ape \
--enable-decoder=ass \
--enable-decoder=atrac1 \
--enable-decoder=atrac3 \
--enable-decoder=atrac3p \
--enable-decoder=cook \
--enable-decoder=dca \
--enable-decoder=dsd_lsbf \
--enable-decoder=dsd_lsbf_planar \
--enable-decoder=dsd_msbf \
--enable-decoder=dsd_msbf_planar \
--enable-decoder=dvbsub \
--enable-decoder=dvdsub \
--enable-decoder=eac3 \
--enable-decoder=evrc \
--enable-decoder=flac \
--enable-decoder=flv \
--enable-decoder=g723_1 \
--enable-decoder=g729 \
--enable-decoder=gif \
--enable-decoder=h261 \
--enable-decoder=h263 \
--enable-decoder=h263i \
--enable-decoder=h264 \
--enable-decoder=hevc \
--enable-decoder=iac \
--enable-decoder=imc \
--enable-decoder=jpeg2000 \
--enable-decoder=jpegls \
--enable-decoder=mace3 \
--enable-decoder=mace6 \
--enable-decoder=metasound \
--enable-decoder=mjpeg \
--enable-decoder=mlp \
--enable-decoder=movtext \
--enable-decoder=mp1 \
--enable-decoder=mp2 \
--enable-decoder=mp3 \
--enable-decoder=mp3adu \
--enable-decoder=mp3adufloat \
--enable-decoder=mp3float \
--enable-decoder=mp3on4 \
--enable-decoder=mp3on4float \
--enable-decoder=mpeg1video \
--enable-decoder=mpeg2video \
--enable-decoder=mpeg4 \
--enable-decoder=nellymoser \
--enable-decoder=opus \
--enable-decoder=pcm_alaw \
--enable-decoder=pcm_bluray \
--enable-decoder=pcm_dvd \
--enable-decoder=pcm_f32be \
--enable-decoder=pcm_f32le \
--enable-decoder=pcm_f64be \
--enable-decoder=pcm_f64le \
--enable-decoder=pcm_lxf \
--enable-decoder=pcm_mulaw \
--enable-decoder=pcm_s16be \
--enable-decoder=pcm_s16be_planar \
--enable-decoder=pcm_s16le \
--enable-decoder=pcm_s16le_planar \
--enable-decoder=pcm_s24be \
--enable-decoder=pcm_s24daud \
--enable-decoder=pcm_s24le \
--enable-decoder=pcm_s24le_planar \
--enable-decoder=pcm_s32be \
--enable-decoder=pcm_s32le \
--enable-decoder=pcm_s32le_planar \
--enable-decoder=pcm_s8 \
--enable-decoder=pcm_s8_planar \
--enable-decoder=pcm_u16be \
--enable-decoder=pcm_u16le \
--enable-decoder=pcm_u24be \
--enable-decoder=pcm_u24le \
--enable-decoder=pcm_u32be \
--enable-decoder=pcm_u32le \
--enable-decoder=pcm_u8 \
--enable-decoder=pgssub \
--enable-decoder=png \
--enable-decoder=qcelp \
--enable-decoder=qdm2 \
--enable-decoder=ra_144 \
--enable-decoder=ra_288 \
--enable-decoder=ralf \
--enable-decoder=s302m \
--enable-decoder=shorten \
--enable-decoder=sipr \
--enable-decoder=sonic \
--enable-decoder=srt \
--enable-decoder=ssa \
--enable-decoder=subrip \
--enable-decoder=subviewer \
--enable-decoder=subviewer1 \
--enable-decoder=tak \
--enable-decoder=text \
--enable-decoder=truehd \
--enable-decoder=truespeech \
--enable-decoder=tta \
--enable-decoder=vorbis \
--enable-decoder=wavpack \
--enable-decoder=wmalossless \
--enable-decoder=wmapro \
--enable-decoder=wmav1 \
--enable-decoder=wmav2 \
--enable-decoder=wmavoice \
--enable-decoder=xsub \
\
--disable-muxers \
--enable-muxer=apng \
--enable-muxer=flac \
--enable-muxer=h261 \
--enable-muxer=h263 \
--enable-muxer=h264 \
--enable-muxer=hevc \
--enable-muxer=image2 \
--enable-muxer=image2pipe \
--enable-muxer=m4v \
--enable-muxer=matroska \
--enable-muxer=mjpeg \
--enable-muxer=mp3 \
--enable-muxer=mp4 \
--enable-muxer=mpeg1video \
--enable-muxer=mpeg2video \
--enable-muxer=mpegts \
--enable-muxer=ogg \
--disable-demuxers \
--enable-demuxer=aac \
--enable-demuxer=ac3 \
--enable-demuxer=apng \
--enable-demuxer=ass \
--enable-demuxer=avi \
--enable-demuxer=dash \
--enable-demuxer=dts \
--enable-demuxer=ffmetadata \
--enable-demuxer=flac \
--enable-demuxer=flv \
--enable-demuxer=gif \
--enable-demuxer=h264 \
--enable-demuxer=hls \
--enable-demuxer=live_flv \
--enable-demuxer=image2 \
--enable-demuxer=image2pipe \
--enable-demuxer=image_bmp_pipe \
--enable-demuxer=image_jpeg_pipe \
--enable-demuxer=image_jpegls_pipe \
--enable-demuxer=image_png_pipe \
--enable-demuxer=m4v \
--enable-demuxer=matroska \
--enable-demuxer=mjpeg \
--enable-demuxer=mov \
--enable-demuxer=mp3 \
--enable-demuxer=mpegps \
--enable-demuxer=mpegts \
--enable-demuxer=mpegtsraw \
--enable-demuxer=mpegvideo \
--enable-demuxer=mpjpeg \
--enable-demuxer=ogg \
--enable-demuxer=pcm_s16be \
--enable-demuxer=pcm_s16le \
--enable-demuxer=rawvideo \
--enable-demuxer=realtext \
--enable-demuxer=rm \
--enable-demuxer=rtp \
--enable-demuxer=rtsp \
--enable-demuxer=srt \
--enable-demuxer=vc1 \
--enable-demuxer=wav \
--enable-demuxer=webm_dash_manifest \
\
--disable-filters \
--enable-filter=drawtext \
--enable-filter=overlay \
--enable-filter=scale \
\
--disable-extra-warnings \
--disable-postproc \
--enable-filter=drawtext \
--enable-filter=overlay \
--enable-filter=scale \
\
--enable-bsfs \
--enable-bzlib \
--enable-libass \
--enable-libbluray \
--enable-libfreetype \
--enable-librtmp \
--enable-libxml2 \
--enable-network \
--enable-nonfree \
--enable-openssl \
@ -305,20 +300,12 @@ FFMPEG_CONF_OPTS = \
--disable-libxcb-xfixes \
--disable-libxcb-shape \
\
--disable-debug \
--enable-cross-compile \
--enable-stripping \
--disable-static \
--enable-shared \
--disable-runtime-cpudetect \
--enable-pic \
--enable-pthreads \
--enable-small \
--enable-swresample \
--enable-hardcoded-tables \
\
--target-os=linux \
--arch=$(TARGET_ARCH) \
--extra-ldflags="$(TARGET_LDFLAGS)"
--enable-hardcoded-tables
BS_PACKAGE_FFMPEG_FFPLAY = no
ifeq ($(BS_PACKAGE_FFMPEG_FFPLAY),yes)
@ -336,8 +323,7 @@ ifeq ($(TARGET_ARCH),arm)
--enable-neon \
--enable-vfp \
\
--cpu=cortex-a15 \
--extra-cflags="-Wno-deprecated-declarations -I$(TARGET_includedir) -mfpu=neon-vfpv4 -mfloat-abi=hard"
--cpu=cortex-a15
else ifeq ($(TARGET_ARCH),mips)
FFMPEG_CONF_OPTS += \
@ -346,19 +332,36 @@ else ifeq ($(TARGET_ARCH),mips)
--disable-neon \
--disable-vfp \
\
--cpu=generic \
--extra-cflags="-Wno-deprecated-declarations -I$(TARGET_includedir)"
--cpu=generic
endif
FFMPEG_CONF_OPTS += \
--prefix=$(prefix) \
--datadir=$(REMOVE_datadir) \
--enable-cross-compile \
--cross-prefix=$(TARGET_CROSS) \
--arch=$(TARGET_ARCH) \
--target-os=linux \
--disable-debug \
--disable-stripping \
--disable-static \
--enable-shared \
--disable-extra-warnings \
--disable-postproc \
--pkg-config="$(PKG_CONFIG)" \
--extra-cflags="$(TARGET_CFLAGS) -Wno-deprecated-declarations" \
--extra-ldflags="$(TARGET_LDFLAGS)"
ffmpeg: $(FFMPEG_DEPENDENCIES) $(DL_DIR)/$(FFMPEG_SOURCE) | $(TARGET_DIR)
$(REMOVE)/$(PKG_DIR)
$(UNTAR)/$(PKG_SOURCE)
$(call DEPENDENCIES)
$(call DOWNLOAD,$($(PKG)_SOURCE))
$(call STARTUP)
$(call EXTRACT,$(BUILD_DIR))
ifneq ($($(PKG)_UNPATCHED),yes)
$(call APPLY_PATCHES,$(PKG_PATCHES_DIR))
endif
$(CHDIR)/$(PKG_DIR); \
$(CHDIR)/$($(PKG)_DIR); \
./configure $($(PKG)_CONF_OPTS); \
$(MAKE); \
$(MAKE) install DESTDIR=$(TARGET_DIR)
$(REMOVE)/$(PKG_DIR)
$(TOUCH)
$(call TARGET_FOLLOWUP)

97
package/ffmpeg/patches/0001-libavutil-include-assembly-with-full-path-from-sourc.patch

@ -0,0 +1,97 @@
From 24a58d70cbb3997e471366bd5afe54be9007bfb1 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Tue, 10 Nov 2020 15:32:14 +0000
Subject: [PATCH] libavutil: include assembly with full path from source root
Otherwise nasm writes the full host-specific paths into .o
output, which breaks binary reproducibility.
Upstream-Status: Pending
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
libavutil/x86/cpuid.asm | 2 +-
libavutil/x86/emms.asm | 2 +-
libavutil/x86/fixed_dsp.asm | 2 +-
libavutil/x86/float_dsp.asm | 2 +-
libavutil/x86/lls.asm | 2 +-
libavutil/x86/pixelutils.asm | 2 +-
6 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/libavutil/x86/cpuid.asm b/libavutil/x86/cpuid.asm
index c3f7866..766f77f 100644
--- a/libavutil/x86/cpuid.asm
+++ b/libavutil/x86/cpuid.asm
@@ -21,7 +21,7 @@
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
;******************************************************************************
-%include "x86util.asm"
+%include "libavutil/x86/x86util.asm"
SECTION .text
diff --git a/libavutil/x86/emms.asm b/libavutil/x86/emms.asm
index 8611762..df84f22 100644
--- a/libavutil/x86/emms.asm
+++ b/libavutil/x86/emms.asm
@@ -18,7 +18,7 @@
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
;******************************************************************************
-%include "x86util.asm"
+%include "libavutil/x86/x86util.asm"
SECTION .text
diff --git a/libavutil/x86/fixed_dsp.asm b/libavutil/x86/fixed_dsp.asm
index 979dd5c..2f41185 100644
--- a/libavutil/x86/fixed_dsp.asm
+++ b/libavutil/x86/fixed_dsp.asm
@@ -20,7 +20,7 @@
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
;******************************************************************************
-%include "x86util.asm"
+%include "libavutil/x86/x86util.asm"
SECTION .text
diff --git a/libavutil/x86/float_dsp.asm b/libavutil/x86/float_dsp.asm
index 517fd63..b773e61 100644
--- a/libavutil/x86/float_dsp.asm
+++ b/libavutil/x86/float_dsp.asm
@@ -20,7 +20,7 @@
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
;******************************************************************************
-%include "x86util.asm"
+%include "libavutil/x86/x86util.asm"
SECTION_RODATA 32
pd_reverse: dd 7, 6, 5, 4, 3, 2, 1, 0
diff --git a/libavutil/x86/lls.asm b/libavutil/x86/lls.asm
index 317fba6..d2526d1 100644
--- a/libavutil/x86/lls.asm
+++ b/libavutil/x86/lls.asm
@@ -20,7 +20,7 @@
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
;******************************************************************************
-%include "x86util.asm"
+%include "libavutil/x86/x86util.asm"
SECTION .text
diff --git a/libavutil/x86/pixelutils.asm b/libavutil/x86/pixelutils.asm
index 36c57c5..8b45ead 100644
--- a/libavutil/x86/pixelutils.asm
+++ b/libavutil/x86/pixelutils.asm
@@ -21,7 +21,7 @@
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
;******************************************************************************
-%include "x86util.asm"
+%include "libavutil/x86/x86util.asm"
SECTION .text

2
package/ffmpeg/patches/4_02_fix_mpegts.patch

@ -1,6 +1,6 @@
--- a/libavformat/mpegts.c
+++ b/libavformat/mpegts.c
@@ -1015,10 +1015,12 @@ static int new_pes_packet(PESContext *pes, AVPacket *pkt)
@@ -1015,10 +1015,12 @@
pes->buffer = NULL;
reset_pes_packet_state(pes);

8
package/ffmpeg/patches/4_03_allow_to_choose_rtmp_impl_at_runtime.patch

@ -1,6 +1,6 @@
--- a/configure
+++ b/configure
@@ -3411,10 +3411,8 @@ xv_outdev_deps="xlib"
@@ -3411,10 +3411,8 @@
# protocols
async_protocol_deps="threads"
bluray_protocol_deps="libbluray"
@ -11,7 +11,7 @@
ffrtmphttp_protocol_select="http_protocol"
ftp_protocol_select="tcp_protocol"
gopher_protocol_select="network"
@@ -3427,20 +3425,18 @@ https_protocol_suggest="zlib"
@@ -3427,20 +3425,18 @@
icecast_protocol_select="http_protocol"
mmsh_protocol_select="http_protocol"
mmst_protocol_select="network"
@ -46,7 +46,7 @@
sctp_protocol_deps="struct_sctp_event_subscribe struct_msghdr_msg_flags"
--- a/libavformat/Makefile
+++ b/libavformat/Makefile
@@ -609,12 +609,12 @@ OBJS-$(CONFIG_MMSH_PROTOCOL) += mmsh.o mms.o asf.o
@@ -609,12 +609,12 @@
OBJS-$(CONFIG_MMST_PROTOCOL) += mmst.o mms.o asf.o
OBJS-$(CONFIG_PIPE_PROTOCOL) += file.o
OBJS-$(CONFIG_PROMPEG_PROTOCOL) += prompeg.o
@ -67,7 +67,7 @@
OBJS-$(CONFIG_SRTP_PROTOCOL) += srtpproto.o srtp.o
--- a/libavformat/protocols.c
+++ b/libavformat/protocols.c
@@ -44,12 +44,12 @@ extern const URLProtocol ff_mmst_protocol;
@@ -44,12 +44,12 @@
extern const URLProtocol ff_md5_protocol;
extern const URLProtocol ff_pipe_protocol;
extern const URLProtocol ff_prompeg_protocol;

2
package/ffmpeg/patches/4_04_hls_replace_key_uri.patch

@ -36,7 +36,7 @@
}
ff_data_to_hex(iv, seg->iv, sizeof(seg->iv), 0);
ff_data_to_hex(key, pls->key, sizeof(pls->key), 0);
@@ -2367,6 +2379,8 @@
@@ -2369,6 +2381,8 @@
INT_MIN, INT_MAX, FLAGS},
{"max_reload", "Maximum number of times a insufficient list is attempted to be reloaded",
OFFSET(max_reload), AV_OPT_TYPE_INT, {.i64 = 1000}, 0, INT_MAX, FLAGS},

10
package/ffmpeg/patches/4_06_optimize_aac.patch

@ -1,6 +1,6 @@
--- a/libavcodec/aacdec_template.c
+++ b/libavcodec/aacdec_template.c
@@ -2485,7 +2485,7 @@ static int decode_extension_payload(AACContext *ac, GetBitContext *gb, int cnt,
@@ -2485,7 +2485,7 @@
* @param decode 1 if tool is used normally, 0 if tool is used in LTP.
* @param coef spectral coefficients
*/
@ -11,7 +11,7 @@
const int mmm = FFMIN(ics->tns_max_bands, ics->max_sfb);
--- a/libavcodec/aacps.c
+++ b/libavcodec/aacps.c
@@ -659,7 +659,7 @@ static void map_val_20_to_34(INTFLOAT par[PS_MAX_NR_IIDICC])
@@ -659,7 +659,7 @@
par[ 1] = AAC_HALF_SUM(par[ 0], par[ 1]);
}
@ -22,7 +22,7 @@
LOCAL_ALIGNED_16(INTFLOAT, transient_gain, [34], [PS_QMF_TIME_SLOTS]);
--- a/libavcodec/fft_template.c
+++ b/libavcodec/fft_template.c
@@ -562,7 +562,7 @@ static void fft##n(FFTComplex *z)\
@@ -562,7 +562,7 @@
pass(z,FFT_NAME(ff_cos_##n),n4/2);\
}
@ -31,7 +31,7 @@
{
FFTDouble t1, t2, t3, t4, t5, t6, t7, t8;
@@ -576,7 +576,7 @@ static void fft4(FFTComplex *z)
@@ -576,7 +576,7 @@
BF(z[2].im, z[0].im, t2, t5);
}
@ -42,7 +42,7 @@
--- a/libavcodec/mdct_template.c
+++ b/libavcodec/mdct_template.c
@@ -102,7 +102,7 @@ av_cold int ff_mdct_init(FFTContext *s, int nbits, int inverse, double scale)
@@ -102,7 +102,7 @@
* @param output N/2 samples
* @param input N/2 samples
*/

71
package/ffmpeg/patches/4_07_increase_buffer_size.patch

@ -1,18 +1,3 @@
--- a/libavformat/avio.h
+++ b/libavformat/avio.h
@@ -290,12 +290,6 @@ typedef struct AVIOContext {
*/
int writeout_count;
- /**
- * Original buffer size
- * used internally after probing and ensure seekback to reset the buffer size
- * This field is internal to libavformat and access from outside is not allowed.
- */
- int orig_buffer_size;
/**
* Threshold to favor readahead over seek.
--- a/libavformat/aviobuf.c
+++ b/libavformat/aviobuf.c
@@ -33,7 +33,7 @@
@ -24,15 +9,7 @@
/**
* Do seeks within this distance ahead of the current buffer by skipping
@@ -85,7 +85,6 @@ int ffio_init_context(AVIOContext *s,
memset(s, 0, sizeof(AVIOContext));
s->buffer = buffer;
- s->orig_buffer_size =
s->buffer_size = buffer_size;
s->buf_ptr = buffer;
s->buf_ptr_max = buffer;
@@ -548,15 +547,15 @@
@@ -548,15 +548,15 @@
}
/* make buffer smaller in case it ended up large after probing */
@ -51,49 +28,3 @@
}
len = read_packet_wrapper(s, dst, len);
@@ -1017,7 +1016,6 @@ int ffio_set_buf_size(AVIOContext *s, int buf_size)
av_free(s->buffer);
s->buffer = buffer;
- s->orig_buffer_size =
s->buffer_size = buf_size;
s->buf_ptr = s->buf_ptr_max = buffer;
url_resetbuf(s, s->write_flag ? AVIO_FLAG_WRITE : AVIO_FLAG_READ);
@@ -1044,7 +1044,6 @@
memcpy(buffer, s->write_flag ? s->buffer : s->buf_ptr, data_size);
av_free(s->buffer);
s->buffer = buffer;
- s->orig_buffer_size = buf_size;
s->buffer_size = buf_size;
s->buf_ptr = s->write_flag ? (s->buffer + data_size) : s->buffer;
if (s->write_flag)
diff --git a/libavformat/utils.c b/libavformat/utils.c
index c25eab4..02ce5e2 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -133,6 +133,25 @@ FF_ENABLE_DEPRECATION_WARNINGS
#endif
#endif
+void *av_fast_realloc(void *ptr, unsigned int *size, size_t min_size)
+{
+ if (min_size < *size)
+ return ptr;
+
+ min_size = FFMAX(17 * min_size / 16 + 32, min_size);
+
+ ptr = av_realloc(ptr, min_size);
+ /* we could set this to the unmodified min_size but this is safer
+ * if the user lost the ptr and uses NULL now
+ */
+ if (!ptr)
+ min_size = 0;
+
+ *size = min_size;
+
+ return ptr;
+}
+
int64_t av_stream_get_end_pts(const AVStream *st)
{
if (st->internal->priv_pts) {

2
package/ffmpeg/patches/4_08_recheck_discard_flags.patch

@ -1,6 +1,6 @@
--- a/libavformat/hls.c
+++ b/libavformat/hls.c
@@ -2140,8 +2140,10 @@
@@ -2142,8 +2142,10 @@
HLSContext *c = s->priv_data;
int ret, i, minplaylist = -1;

0
package/ffmpeg/patches/4_10_rtsp_patch → package/ffmpeg/patches/4_11_rtsp.patch

0
package/ffmpeg/patches/4_11_dxva2_patch → package/ffmpeg/patches/4_12_dxva2.patch

14
package/ffmpeg/patches/4_A02-corrupt-h264-frames.patch

@ -1,14 +0,0 @@
--- a/libavcodec/h264_slice.c
+++ b/libavcodec/h264_slice.c
@@ -1460,6 +1460,11 @@
h->avctx->has_b_frames = sps->num_reorder_frames;
}
+ if (sps && sps->bitstream_restriction_flag &&
+ h->avctx->has_b_frames < sps->num_reorder_frames) {
+ h->avctx->has_b_frames = FFMAX(h->avctx->has_b_frames, sps->num_reorder_frames);
+ }
+
last_pic_droppable = h->droppable;
last_pic_structure = h->picture_structure;
h->droppable = (nal->ref_idc == 0);

78
package/ffmpeg/patches/4_A11-FFmpeg-devel-amfenc-Add-support-for-pict_type-field.patch

@ -1,78 +0,0 @@
From patchwork Mon Jan 14 19:02:20 2019
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Subject: [FFmpeg-devel] amfenc: Add support for pict_type field
From: Michael Fabian 'Xaymar' Dirks <info@xaymar.com>
X-Patchwork-Id: 11748
Message-Id: <20190114190220.16236-1-info@xaymar.com>
To: ffmpeg-devel@ffmpeg.org
Cc: Michael Fabian 'Xaymar' Dirks <info@xaymar.com>
Date: Mon, 14 Jan 2019 20:02:20 +0100
Adds support for the pict_type field in AVFrame to amf_h264 and amf_h265 simultaneously. This field is needed in cases where the application wishes to override the frame type with another one, such as forcefully inserting a key frame for chapter markers or similar.
Additionally this abuses AV_PICTURE_TYPE_S for marking Skip frames, a special type of frame in AVC, SVC and HEVC which is a flag for the decoder to repeat the last frame.
Signed-off-by: Michael Fabian 'Xaymar' Dirks <info@xaymar.com>
---
libavcodec/amfenc.c | 46 +++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 46 insertions(+)
diff --git a/libavcodec/amfenc.c b/libavcodec/amfenc.c
index 384d8efc92..eb4b65e4f2 100644
--- a/libavcodec/amfenc.c
+++ b/libavcodec/amfenc.c
@@ -693,6 +693,52 @@ int ff_amf_send_frame(AVCodecContext *avctx, const AVFrame *frame)
break;
}
+ // Override Picture Type for Frame
+ if (avctx->codec->id == AV_CODEC_ID_H264) {
+ switch (frame->pict_type) {
+ case AV_PICTURE_TYPE_I:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_PICTURE_TYPE_I);
+ break;
+ case AV_PICTURE_TYPE_P:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_PICTURE_TYPE_P);
+ break;
+ case AV_PICTURE_TYPE_B:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_PICTURE_TYPE_B);
+ break;
+ case AV_PICTURE_TYPE_S:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_PICTURE_TYPE_SKIP);
+ break;
+ default:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_PICTURE_TYPE_NONE);
+ break;
+ }
+ // Keyframe overrides previous assignment.
+ if (frame->key_frame) {
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_PICTURE_TYPE_IDR);
+ }
+ } else if (avctx->codec->id == AV_CODEC_ID_HEVC) {
+ switch (frame->pict_type) {
+ case AV_PICTURE_TYPE_I:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_HEVC_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_HEVC_PICTURE_TYPE_I);
+ break;
+ case AV_PICTURE_TYPE_P:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_HEVC_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_HEVC_PICTURE_TYPE_P);
+ break;
+ case AV_PICTURE_TYPE_B:
+ av_log(ctx, AV_LOG_WARNING, "Ignoring B-Frame, unsupported by AMD AMF H.265 Encoder.");
+ break;
+ case AV_PICTURE_TYPE_S:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_HEVC_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_HEVC_PICTURE_TYPE_SKIP);
+ break;
+ default:
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_HEVC_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_HEVC_PICTURE_TYPE_NONE);
+ break;
+ }
+ // Keyframe overrides previous assignment.
+ if (frame->key_frame) {
+ AMF_ASSIGN_PROPERTY_INT64(res, surface, AMF_VIDEO_ENCODER_HEVC_FORCE_PICTURE_TYPE, AMF_VIDEO_ENCODER_HEVC_PICTURE_TYPE_IDR);
+ }
+ }
// submit surface
res = ctx->encoder->pVtbl->SubmitInput(ctx->encoder, (AMFData*)surface);

2
package/ffmpeg/patches/4_mips64_cpu_detection.patch

@ -15,7 +15,7 @@ Upstream-Status: Inappropriate [OE-Specific]
--- a/configure
+++ b/configure
@@ -5847,12 +5847,9 @@ elif enabled mips; then
@@ -5847,12 +5847,9 @@
# Enable minimum ISA based on selected options
if enabled mips64; then

Loading…
Cancel
Save