configure: Use MSYSTEM_CARCH for default arch on msys2 On msys2, `uname -m` returns the architecture of the base msys2 layer. On Windows on arm64, the base msys2 layer itself is still x86_64 only, even if running with e.g. the clangarm64 where the windows native applications are built as aarch64. If MSYSTEM_CARCH is set, use this instead of `uname -m` for the default architecture. This gives the correct behaviour for the clangarm64 environments. It also gives the correct default for the 32 bit x86 environments such as `mingw32`. (On `mingw32`, the fact that `uname -m` returned `x86_64` hasn't been an issue, as both that and `i686` gets normalized into `x86` internally in ffmpeg's configure.) Signed-off-by: Coia Prant <coiaprant@gmail.com> Signed-off-by: Martin Storsj? <martin@martin.st> (cherry picked from commit df967d095ae6a42a46cd4c46b96d61cc1c319b23)
lsws/ppc/yuv2rgb_altivec: Fix build in non-VSX environments with Clang Add a check for the existence of the vec_xl() function. Clang provides the function even with VSX not enabled. (cherry picked from commit 30a8641465f7b7923e92d8724ef6a595fccb9e58) Signed-off-by: Brad Smith <brad@comstyle.com>
riscv: test for assembler support This should fix the build on LLVM 16 and earlier, at the cost of turning all non-RVV optimisations off. Signed-off-by: Brad Smith <brad@comstyle.com>
avcodec/libx265: unbreak build for X265_BUILD >= 213 Earlier, x265 made an API change to support alpha and other multiple layer pictures. We added guards to accommodate that in 1f801dfdb5 They have now reverted that API change in https://bitbucket.org/multicoreware/x265_git/commits/78e5b703b1 Updated our wrapper guards to unbreak build again.
lavc/hevcdec: set per-CTB filter parameters for WPP Fixes #10887 (cherry picked from commit 536bb988889eec08c5a1d5fd733f9e98569ae65e) Signed-off-by: Anton Khirnov <anton@khirnov.net> (cherry picked from commit f705bc5b7333ed45d476f473df8f6bf893e867e2) Signed-off-by: Anton Khirnov <anton@khirnov.net>
lavc/hevc: check framerate num/den to be strictly positive Rather than just != 0. These values are read as uint32 and can become negative when cast to int. (cherry picked from commit eec1a7a6bb952c09945d908d2d5de35909516778) Signed-off-by: Anton Khirnov <anton@khirnov.net> (cherry picked from commit 9cadadb9a12aaf30b196c896073c473d91a2bdf0) Signed-off-by: Anton Khirnov <anton@khirnov.net>
lavc/libx265: unbreak build for X265_BUILD >= 210 x265 added support for alpha starting with build 210. While doing so, x265_encoder_encode() changed its fifth arg to an array of pointers to x265_picture. This broke building lavc/libx265.c This patch simply unbreaks the build and maintains existing single-layer non-alpha encoding support. Fixes #11130
configure: improve check for POSIX ioctl Instead of relying on system #ifdefs which may or may not be correct, detect the POSIX ioctl signature at configure time. (cherry picked from commit 00b64fca55a3a009c9d0e391c85f4fd3291e5d12) Signed-off-by: Brad Smith <brad@comstyle.com>
libavcodec/arm/mlpdsp_armv5te: fix label format to work with binutils 2.43 binutils 2.43 has stricter validation for labels[1] and results in errors when building ffmpeg for armv5: src/libavcodec/arm/mlpdsp_armv5te.S:232: Error: junk at end of line, first unrecognized character is `0' Remove the leading zero in the "01" label to resolve this error. [1] https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=226749d5a6ff0d5c607d6428d6c81e1e7e7a994b Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Martin Storsj? <martin@martin.st> (cherry picked from commit 654bd47716c4f36719fb0f3f7fd8386d5ed0b916)
avcodec/nvenc: fix segfault in intra-only mode In intra-only mode, frameIntervalP is 0, which means the frame data array is smaller than the number of surfaces. Together with using the wrong size on deallocation of the frame_data_array, this lead to a crash. Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org> (cherry picked from commit c9151ea50715c4ce47ad1c8df519781565db01f6)
lavc/vp9: reset segmentation fields when segmentation isn't enabled Fields under the segmentation switch are never reset on a new frame, and retain the value from the previous frame. This bugs out a bunch of hwaccel drivers when segmentation is disabled but update_map isn't reset because they don't ignore values behind switches. This commit also resets the temporal field, though it may not be required. We also do this for vp8 [1] so this commit is just mirroring the vp8 logic. This fixes an issue with certain samples [2] that causes blocky artifacts with vaapi, d3d11va and cuda (and possibly others). Mesa worked around [3] this by ignoring these fields if segmentation.enabled is 0, but d3d11va still displays blocky artifacts. [1] https://git.ffmpeg.org/gitweb/ffmpeg.git/blob/2e877090f958131accb8c7e5ac10e5b9865d1735:/libavcodec/vp8.c#l797 [2] https://github.com/mpv-player/mpv/issues/13533 [3] https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27816 Signed-off-by: llyyr <llyyr.public@gmail.com>
avcodec/x86/vp3dsp_init: Set correct function pointer, fix crash Regression since fd172185580c1ccdcfb90bbfdb59fa806fad3117; triggered by vp4/KTkvw8dg1J8.avi in the FATE suite, but not when running fate as this code is not used when the bitexact flag is set. Bisecting done by ami_stuff, patch from user Mika Fischer in ticket #10027 (which this commit fixes). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> (cherry picked from commit c3ca90a92e7211aef8ad1d044518a34f6ba137d7)