Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-06-10configure: extend SDL check to accept all 2.x versionsChristopher Degawa
sdl2 recently changed their versioning, moving the patch level to minor level https://github.com/libsdl-org/SDL/commit/cd7c2f1de7d9e418bb554047d714dd7cacc020ff and have said that they will instead ship sdl3.pc for 3.0.0 Fixes ticket 9768 Signed-off-by: Christopher Degawa <ccom@randomderp.com> Signed-off-by: Gyan Doshi <ffmpeg@gyani.pro>
2022-01-21configure: link to libatomic when it's presentAnton Khirnov
C11 atomics in some configurations (e.g. 64bit operations on ppc64 with GCC) require linking to libatomic. Fixes #9275 (cherry picked from commit 2f0a214a6202516b4dda2bb22b6b3ac20e465d6d) Signed-off-by: Anton Khirnov <anton@khirnov.net>
2022-01-08avformat/matroskaenc: Disable MKV-only code if MKV muxer is disabledAndreas Rheinhardt
The Matroska muxer has quite a lot of dependencies and lots of them are unnecessary for WebM. By disabling the Matroska-only code at compile time one can get rid of them. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> (cherry picked from commit 52c1e9e530a46ba62b974f121c9d28a86900a632)
2022-01-08configure: Let decklink indev suggest libzvbiAndreas Rheinhardt
Fixes build errors if libzvbi is enabled while libzvbi_teletextdec is disabled. Reviewed-by: Marton Balint <cus@passwd.hu> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> (cherry picked from commit 2d0b17e820b84cceb95c29557e168a6ef98d4ce1)
2022-01-07configure: Add missing AMV muxer->riffenc dependencyAndreas Rheinhardt
Reviewed-by: Zane van Iperen <zane@zanevaniperen.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> (cherry picked from commit 41c62207f641b5cf3ae656068652f7dc958d5e79)
2022-01-06configure: Add missing libshine->mpegaudioheader dependencyAndreas Rheinhardt
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> (cherry picked from commit e228d7b0db7d6cb02a73bee6d3bf4f6ecf92d0bf)
2022-01-05lavfi/libplacebo: support dovi metadata applicationNiklas Haas
libplacebo supports automatic dolby vision application, but it requires us to switch to a new API. Also add some logic to strip the dolby vision metadata from the output frames in any case where we end up changing the colorimetry. The libplacebo dependency bump is justified because neither 184 nor 192 are part of any stable libplacebo release, so users have to build from git anyways for this filter to exist. Signed-off-by: Niklas Haas <git@haasn.dev>
2022-01-04configure, avcodec/Makefile: Add new mpeg4audio CONFIG_EXTRA groupAndreas Rheinhardt
This group is mainly for the users of *_mpeg4audio_get_config2(); it is not for those who only use avpriv_mpeg4audio_sample_rates. This is in preparation for splitting the latter into a file of its own; if there were no CONFIG_EXTRA group for *_mpeg4audio_get_config2() users, one would have to add a dependency to the new file for all these users on top of the existing dependency on mpeg4audio.o. Adding a new CONFIG_EXTRA group only takes effect after a reconfigure; so in order to force a reconfigure some unnecessary headers from libavdevice/alldevices.c have been removed. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-01-04avcodec/jpegtables: Unavpriv MJPEG-tablesAndreas Rheinhardt
There are seven MJPEG-tables, five small (1x12, 4x17) and two not small (2x162). These are all avpriv, despite this not being worthwhile due to the overhead of exporting a symbol: The total overhead for each symbol consists of two entries in .dynsym (24B each), one entry in the importing library's .rela.dyn (24B) and one in .got (8B) as well as 2x2B for symbol versions and 4B for symbol hashes in the exporting library; in addition to that, the name of the symbol is included in both exporting and importing libraries, using 2x210 bytes in this case. (The above numbers are for a x64 Elf/Linux/GNU system. Other platforms will give different numbers.) Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-01-04lavc/hevcdec: Parse DOVI RPU NALsNiklas Haas
And expose the parsed values as frame side data. Update FATE results to match. It's worth documenting that this relies on the dovi configuration record being present on the first AVPacket fed to the decoder, which in practice is the case if if the API user has called something like av_format_inject_global_side_data, which is unfortunately not the default. This commit is not the time and place to change that behavior, though. Signed-off-by: Niklas Haas <git@haasn.dev> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-01-04lavc: Implement Dolby Vision RPU parsingNiklas Haas
Based on a mixture of guesswork, partial documentation in patents, and reverse engineering of real-world samples. Confirmed working for all the samples I've thrown at it. Contains some annoying machinery to persist these values in between frames, which is needed in theory even though I've never actually seen a sample that relies on it in practice. May or may not work. Since the distinction matters greatly for parsing the color matrix values, this includes a small helper function to guess the right profile from the RPU itself in case the user has forgotten to forward the dovi configuration record to the decoder. (Which in practice, only ffmpeg.c and ffplay do..) Notable omissions / deviations: - CRC32 verification. This is based on the MPEG2 CRC32 type, which is similar to IEEE CRC32 but apparently different in subtle enough ways that I could not get it to pass verification no matter what parameters I fed to av_crc. It's possible the code needs some changes. - Linear interpolation support. Nothing documents this (beyond its existence) and no samples use it, so impossible to implement. - All of the extension metadata blocks, but these contain values that seem largely congruent with ST2094, HDR10, or other existing forms of side data, so I will defer parsing/attaching them to a future commit. - The patent describes a mechanism for predicting coefficients from previous RPUs, but the bit for the flag whether to use the prediction deltas or signal entirely new coefficients does not seem to be present in actual RPUs, so we ignore this subsystem entirely. - In the patent's spec, the NLQ subsystem also loops over num_nlq_pivots, but even in the patent the number is hard-coded to one iteration rather than signalled. So we only store one set of coefs. Heavily influenced by https://github.com/quietvoid/dovi_tool Documentation drawn from US Patent 10,701,399 B2 and ETSI GS CCM 001 Signed-off-by: Niklas Haas <git@haasn.dev> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-01-04Makefile: Redo duplicating object files in shared buildsAndreas Rheinhardt
In case of shared builds, some object files containing tables are currently duplicated into other libraries: log2_tab.c, golomb.c, reverse.c. The check for whether this is duplicated is simply whether CONFIG_SHARED is true. Yet this is crude: E.g. libavdevice includes reverse.c for shared builds, but only needs it for the decklink input device, which given that decklink is not enabled by default will be unused in most libavdevice.so. This commit changes this by making it more explicit about what to duplicate from other libraries. To do this, two new Makefile variables were added: SHLIBOBJS and STLIBOBJS. SHLIBOBJS contains the objects that are duplicated from other libraries in case of shared builds; STLIBOBJS contains stuff that a library has to provide for other libraries in case of static builds. These new variables provide a way to enable/disable with a finer granularity than just whether shared builds are enabled or not. E.g. lavd's Makefile now contains: SHLIBOBJS-$(CONFIG_DECKLINK_INDEV) += reverse.o Another example is provided by the golomb tables. These are provided by lavc for static builds, even if one uses a build configuration that makes only lavf use them. Therefore lavc's Makefile contains STLIBOBJS-$(CONFIG_MXF_MUXER) += golomb.o, whereas lavf's Makefile has a corresponding SHLIBOBJS-$(CONFIG_MXF_MUXER) += golomb_tab.o. E.g. in case the MXF muxer is the only component needing these tables only libavformat.so will contain them for shared builds; currently libavcodec.so does so, too. (There is currently a CONFIG_EXTRA group for golomb. But actually one would need two groups (golomb_avcodec and golomb_avformat) in order to know when and where to include these tables. Therefore this commit uses a Makefile-based approach for this and stops using these groups for the users in libavformat.) Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-01-03configure: Make IMF demuxer require MXF demuxerAndreas Rheinhardt
The former is useless without the latter. Reviewed-by: Zane van Iperen <zane@zanevaniperen.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2021-12-31configure: bump yearGyan Doshi
2021-12-31avformat/imf: DemuxerPierre-Anthony Lemieux
Signed-off-by: Pierre-Anthony Lemieux <pal@palemieux.com> Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
2021-12-23configure: use pkg-config for sndioBrad Smith
2021-12-23configure: test the metal compiler before usercombs
Apparently Metal.framework is included with the command line tools (and thus may be present without Xcode), but the Metal compiler is only included as part of Xcode.
2021-12-23configure: ensure we use the macOS SDK's metal compiler by defaultrcombs
Apparently on some OS and Xcode versions this can select an iOS SDK, which in turn may fail on the affected versions.
2021-12-23configure: fix .d generation for C++ and Obj-C filesrcombs
2021-12-23configure: fix setting OBJCCFLAGSrcombs
We call this OBJCFLAGS in help text, but common.mak looks for OBJCCFLAGS.
2021-12-23lavc/videotoolboxenc: add ProRes supportrcombs
2021-12-21configure: improve non-pkgconfig Vulkan version checkLynne
Check for the patch version as well as the major+minor version. The VK_API_VERSION macros are not usable in preprocessor code due to casts. The patch (header) version is meant to linearly increment and not be reset, however it's better to trust, but verify.
2021-12-21configure: autodetect vulkanLynne
2021-12-19configure: fix metal detection and respect explicit disableAman Karmani
Signed-off-by: Aman Karmani <aman@tmm1.net>
2021-12-18avfilter: add vf_yadif_videotoolboxAman Karmani
deinterlaces CVPixelBuffers, i.e. AV_PIX_FMT_VIDEOTOOLBOX frames for example, an interlaced mpeg2 video can be decoded by avcodec, uploaded into a CVPixelBuffer, deinterlaced by Metal, and then encoded to h264 by VideoToolbox as follows: ffmpeg \ -init_hw_device videotoolbox \ -i interlaced.ts \ -vf hwupload,yadif_videotoolbox \ -c:v h264_videotoolbox \ -b:v 2000k \ -c:a copy \ -y progressive.ts (note that uploading AVFrame into CVPixelBuffer via hwupload requires 504c60660d3194758823ddd45ceddb86e35d806f) this work is sponsored by Fancy Bits LLC Reviewed-by: Ridley Combs <rcombs@rcombs.me> Reviewed-by: Philip Langdale <philipl@overt.org> Signed-off-by: Aman Karmani <aman@tmm1.net>
2021-12-18build: detect Metal.framework and build .metal filesAman Karmani
Reviewed-by: Ridley Combs <rcombs@rcombs.me> Signed-off-by: Aman Karmani <aman@tmm1.net>
2021-12-16vf_libplacebo: switch to newer libplacebo helpersNiklas Haas
Support for mapping/unmapping hardware frames has been added into libplacebo itself, so we can scrap this code in favor of using the new functions. This has the additional benefit of being forwards-compatible as support for more complicated frame-related state management is added to libplacebo (e.g. mapping dolby vision metadata). It's worth pointing out that, technically, this would also allow `vf_libplacebo` to accept, practically unmodified, other frame types (e.g. vaapi or drm), or even software input formats. (Although we still need a vulkan *device* to be available) To keep things simple, though, retain the current restriction to vulkan frames. It's possible we could rethink this in a future commit, but for now I don't want to introduce any more potentially breaking changes.
2021-12-15avutil: [loongarch] Add support for loongarch SIMD.Shiyou Yin
LSX and LASX is loongarch SIMD extention. They are enabled by default if compiler support it, and can be disabled with '--disable-lsx' '--disable-lasx'. Change-Id: Ie2608ea61dbd9b7fffadbf0ec2348bad6c124476 Reviewed-by: Shiyou Yin <yinshiyou-hf@loongson.cn> Reviewed-by: guxiwei <guxiwei-hf@loongson.cn> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2021-12-10avfilter: add a transpose_vulkan filterWu Jianhua
The following command is on how to apply transpose_vulkan filter: ffmpeg -init_hw_device vulkan -i input.264 -vf \ hwupload=extra_hw_frames=16,transpose_vulkan,hwdownload,format=yuv420p output.264 Signed-off-by: Wu Jianhua <jianhua.wu@intel.com>
2021-12-07lavfi/vf_subtitles: stop using deprecated ass_set_aspect_ratio()Anton Khirnov
It has been deprecated in favor of ass_set_pixel_aspect() since version 0.11.0, roughly ~2014. Even Debian oldoldstable (stretch) has 0.13.
2021-12-02avfilter: add a flip_vulkan filterWu Jianhua
This filter flips the input video both horizontally and vertically in one compute pipeline, and it's no need to use two pipelines for hflip_vulkan,vflip_vulkan anymore. Signed-off-by: Wu Jianhua <jianhua.wu@intel.com>
2021-12-01configure: Add support for loongarch.Shiyou Yin
For la464 cpu: ./configure --cpu=la464 With cross-compiler: ./configure --cross-prefix=loongarch64-linux-gnu- \ --enable-cross-compile --arch=loongarch64 \ --target-os=linux --cpu=la464 Reviewed-by: 陈昊 <chenhao@loongson.cn> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2021-11-29lavc/proresdec: add videotoolbox hwaccelrcombs
2021-11-29lavc/videotoolbox: add VP9 hardware accelerationrcombs
On M1 Max, this supports profiles 0 and 2, but not 1 and 3.
2021-11-29lavu/videotoolbox: add 422 and 444 pixel format mappingsrcombs
2021-11-27configure: fix test_pkg_config_cpp after 1e5acc1b5985c58eLynne
2021-11-26Revert "Disable warnings for casting pointers to integers, there is nothing ↵Andreas Rheinhardt
wrong with that." This reverts commit 5258f64a14713499cf84840b3ab3a1ee7cdcaeb8. The premise of said commit (that conversions from pointer to int are ok) is wrong: C99/C11 6.3.2.3 5: "Any pointer type may be converted to an integer type. [...] If the result cannot be represented in the integer type, the behavior is undefined." (C90 6.3.4 contains a similar restriction.) So don't disable -Wpointer-to-int-cast. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2021-11-26configure: do not include -lvulkan to cflags in vulkan's pkg-config checkLynne
Also fixes the non-pkg-config check.
2021-11-19avfilter: add a vflip_vulkan filterWu Jianhua
The following command is on how to apply vflip_vulkan filter: ffmpeg -init_hw_device vulkan -i input.264 -vf hwupload=extra_hw_frames=16,vflip_vulkan,hwdownload,format=yuv420p output.264 Signed-off-by: Wu Jianhua <jianhua.wu@intel.com>
2021-11-19avfilter: add a hflip_vulkan filterWu Jianhua
The following command is on how to apply hflip_vulkan filter: ffmpeg -init_hw_device vulkan -i input.264 -vf hwupload=extra_hw_frames=16,hflip_vulkan,hwdownload,format=yuv420p output.264 Signed-off-by: Wu Jianhua <jianhua.wu@intel.com>
2021-11-19lavu/vulkan: add support for using libshaderc as a GLSL compilerLynne
It's got a much better API that's actually maintained, it eliminates race conditions, it comes with a pkg-config file by default, and unfortunately isn't currently packaged by Debian or other large distributions.
2021-11-19lavu/vulkan: move common Vulkan code from libavfilter to libavutilLynne
2021-11-16libavfilter: add a gblur_vulkan filterWu Jianhua
This commit adds a powerful and customizable gblur Vulkan filter, which provides a maximum 127x127 kernel size of Gaussian Filter. The size could be adjusted by requirements on quality or performance. The following command is on how to apply gblur_vulkan filter: ffmpeg -init_hw_device vulkan -i input.264 -vf hwupload=extra_hw_frames=16,gblur_vulkan,hwdownload,format=yuv420p output.264 Signed-off-by: Wu Jianhua <jianhua.wu@intel.com>
2021-11-12lavfi: add a libplacebo filterNiklas Haas
This filter conceptually maps the libplacebo `pl_renderer` API into libavfilter, which is a high-level image rendering API designed to work with an RGB pipeline internally. As such, there's no way to avoid e.g. chroma interpolation with this filter, although new versions of libplacebo support outputting back to subsampled YCbCr after processing is done. That being said, `pl_renderer` supports automatic integration of the majority of libplacebo's shaders, ranging from debanding to tone mapping, and also supports loading custom mpv-style user shaders, making this API a natural candidate for getting a lot of functionality out of relatively little code. In the future, I may approach this problem either by rewriting this filter to also support a non-renderer codepath, or by upgrading libplacebo's renderer to support a full YCbCr pipeline. This unfortunately requires a very new version of libplacebo (unreleased at time of writing) for timeline semaphore support. But the amount of boilerplate needed to hack in backwards compatibility would have been very unreasonable.
2021-11-12lavfi/glslang: migrate to the C API and robustify library detectionLynne
Finally, this is as close to usable as it gets for glslang. Much faster to compile as well, and eliminates the need for a C++ compiler, which is great. Also, changes to the resource limits won't break users, as we can use designated initializers in C90.
2021-11-12lavfi/vulkan: use libavutil's vulkan loaderLynne
This finally fully eliminates the need to statically link to libvulkan!
2021-11-12hwcontext_vulkan: bump required Vulkan loader version to 1.2Lynne
2021-11-03avfilter/scale_npp: add scale2ref_npp filterRoman Arzumanyan
Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
2021-11-03avutil/hwcontext_videotoolbox: fix use of unknown builtin '__builtin_available'Limin Wang
OSX version: 10.11.6 Apple LLVM version 8.0.0 (clang-800.0.42.1) Target: x86_64-apple-darwin15.6.0 Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
2021-10-29configure: add initial RISC-V supportBrad Smith
OpenBSD only supports riscv64 but this is an attempt at adding some of the initial bits for RISC-V support. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>