FFmpeg
FFmpeg is a popular open-source multimedia framework commonly used for audio/video encode and decode functionality to a variety of codecs.
www.ffmpeg.org
Yesterday's Activity
- avformat/jpegmpfdec: add -loop and -framerate options
Niklas Haas: Otherwise this demuxer would regress relative to image2 for basic JPEG inputs that happen to contain an HDR gain map, which are often produced by e.g. - avformat/jpegmpfdec: add JPEG Multi-Picture Format demuxer
Niklas Haas: This format is only auto-probed when we can be certain that the image is a JPEG MPF file; as evidenced either by the extension (.mpo), or by the presence of an MPF APP2 marker or an ISO21496 gain map stub.
This does require parsing possibly arbitrarily far into the file, since the MPF header can be after a > 2 KB EXIF header; and this matches files produced in the wild (by e.g. - avcodec: implement ISO 21496 gain map parsing
Niklas Haas: The parsing logic for this already existed in libavcodec, but was unused until now. - avformat/network: add a wakeup channel for blocking waits
Zhao Zhili: ff_network_wait_fd() can only return after its poll() slice, so a thread blocked in it notices a request from another thread up to POLLING_TIME late. - avformat: discard the priming or the seek pre-roll after a seek
Romain Beauxis: After avformat_seek_file(), the decoder is not told what to discard from what it decodes: the frames over the pre-roll are not reliable, and a seek that lands inside the priming at the start of the stream outputs the rest of it. - avformat/seek: keep the target inside the range when rescaling it
Romain Beauxis: ff_rescale_interval() rounds the bounds of the range inwards and the target to the nearest, so a target close to a bound could fall outside the range, which the seek then rejects. - tests/fate: show seeks on staggered streams, through concat and near an unknown start
Romain Beauxis: Seek on the later of two AAC streams starting a second apart, remuxed from one sample, close enough to its start that the seek targets it; seek through the concat demuxer, which seeks in the file it reads; and seek close to the start of ADTS, whose start time is unknown. - tests/fate: show a seek past the end of a stream and a seek on video
Romain Beauxis: Seek past the end of AAC in CAF and Opus in Matroska, so that the seek lands on the last packet, which carries the padding to discard at the end of the stream. - tests/fate: show the priming and pre-roll of audio codecs across containers
Romain Beauxis: Discarding samples at the start of a stream and after a seek should work the same way for every codec that needs it, whatever the container.
For AAC in MP4, CAF, ADTS, FLV and Matroska, Opus in Ogg, Matroska, CAF and MPEG-TS, and MP3 with LAME and iTunes gapless info, print the priming and pre-roll declared for the audio stream, list the first packets read after a seek to 0.53 s, and decode 0.15 s from there. - libavformat/tests/seek: add an option to set the start of a forward seek
Romain Beauxis: The first seek done with -seekforw asks for a range that starts at the target, so it can never land before it. - avcodec/bsf: add the side_data bitstream filter
Romain Beauxis: Add a filter that removes side data of the given types from packets and from the stream, or keeps only the packets carrying side data of any of the given types, as the select mode of the sidedata frame filter does for frames, but with a list of types. - avcodec/packet_internal: add a handle for each side data type
Romain Beauxis: Add a list that gives each side data type a short handle made of lower case letters, digits and underscores, so that a filter can let its user name a type in an option.
The side_data_prefer_packet option of decoders now takes its constants from this list, which gives the list the names that option has already released. - tests/fate: add an ID3v2 chapter size round-trip
Jun Zhao: Cover ID3v2.3 and ID3v2.4 with a chapter title long enough that a plain size and a synchsafe size differ.
Other Activity This Week
- avcodec/version: fix minor version
James Almer: It was wrongly reduced in 0ec6a0872d2aadbf664820487d037479957fd108. - avcodec/x86/vvc: add AVX2 pred_planar
Marcos Ashton Iglesias: Widths 4 to 64 at 8 bit, with the height a runtime argument as in the C code. - avutil/hwcontext_cuda: support frames with negative linesizes
Michael Niedermayer: A bottom-up software frame, as vflip produces, was handed to cuMemcpy2DAsync() with its negative linesize as the pitch and copy width, which the driver rejected, so uploading or downloading such a frame failed. - avutil/hwcontext_cuda: allocate transfer buffers from page-locked memory
Michael Niedermayer: The device transfers directly to and from page-locked host memory, while pageable memory is copied through a buffer of the driver. - avcodec/mediacodecdec_common: ignore stream info of the initial format
Zhao Zhili: Until the codec signals INFO_OUTPUT_FORMAT_CHANGED, MediaCodec returns the output format set up at configure time. - swscale/ops: add SwsPixelType to SwsClearOp
Niklas Haas: Since SwsOp.type will be deprecated. - swscale/ops: add type[4] to SwsLinearOp
Niklas Haas: Again, op->type is being replaced by more tightly scoped sources of truth. - swscale/ops: add link back to owning SwsOpList
Niklas Haas: This makes some helper functions more convenient to implement in a way that's less dependent on SwsOpList design decisions, and without requiring threading that parameter through every function. - tests/swscale: compare unscaled conversion across thread counts
Michael Niedermayer: Compare one-thread conversion with 2, 3, 7 and 16 threads for five even frame heights, including cases that otherwise produce odd slices. - swscale/arm: align unscaled NEON YUV to RGB slices to source chroma
Michael Niedermayer: The 32-bit ARM NEON YUV-to-RGB converters selected by SET_FF_NVX_TO_RGBX_FUNC share the even-slice precondition with their AArch64 counterparts: for vertically subsampled input they process two luma rows per iteration, so an odd slice boundary picks the wrong chroma phase and the last iteration writes one row past the slice end. - swscale/aarch64: align unscaled YUV to RGB slices to source chroma
Kevin Watters: The NV12 and NV21 NEON converters need even slice boundaries, but the RGB destination only requests one-row alignment. - avfilter/vf_codecview: compute the arrow head length in 64bit
Michael Niedermayer - avfilter/dnn: implement D3D12 DirectML zero-copy for ONNX Runtime backend
Steven Xiao: This commit enables the DNN video filter to run entirely on the GPU for the full D3D12 pipeline (decode, AI inference, and encode) without ever copying frames back to system memory, making it significantly faster on D3D12 hardware.
Benchmarked the new zero-copy D3D12/DirectML DNN pipeline against the existing CPU round-trip pipeline on three major GPU vendors; up to 10x throughput improvement was measured across every vendor.
Add dnn_onnx_d3d12, a helper that binds the DirectML execution provider to a D3D12VA input frame's own device and does NV12 texture<->tensor conversion on the GPU (CopyTextureRegion + compute shaders), avoiding a host round-trip.
dnn_processing negotiates this automatically for D3D12 NV12 input with device=dml. - avcodec/libaribcaption: make the default alpha values unsigned
Michael Niedermayer: ARIBCC_MAKE_RGBA() shifts the alpha value left by 24 bits, which does not fit in an int for the defaults 0xFF and 0x80. - avformat: remove the asf_o demuxer
Michael Niedermayer: asf_o is a second, non-default implementation of the ASF demuxer next to asfdec_f.c. - swscale: gate Vulkan support on the SPIR-V backend being available
Ramiro Polla: If Vulkan was enabled but no SPIR-V headers were found, the Vulkan code in swscale was still compiled, but no backend was exported. - forgejo/workflows: add a native loongarch64 runner to the fate matrix
jinbo: The linux-loongarch64 entry runs the same fate job on native LoongArch64 hardware (Loongson-3C5000, 64 cores) instead of emulating it with qemu. - avformat/mxfenc: write the actual FFV1 version in the FFV1 sub-descriptor
ykisana: Fixes issue due to MXF muxer writing FFV1Version by copying byte 14 of the FFV1 codec label. - avcodec/tiff: clear the separated intermediate buffer
Ayoub Nabil Boubagrat: Strip decoding errors are tolerated unless AV_EF_EXPLODE is set. - avcodec/amrnbdec: conceal lost speech frames
Jun Zhao: During speech, NO_DATA frames were emitted as digital silence, while speech frames marked bad were decoded without concealment. - avcodec/amrnbdata: add the error concealment tables
Jun Zhao: Add the window build_CN_param() in 3GPP TS 26.073 uses as the pseudo-random source when substituting a lost speech frame. - avcodec/amrnbdec: generate comfort noise for SID frames
Jun Zhao: SID frames returned AVERROR_PATCHWELCOME and NO_DATA frames were rejected, so a DTX stream decoded short.
Decode the 39-bit SID and follow TS 26.073 in floating point. - avcodec/amrnbdata: add the comfort noise tables
Jun Zhao: Add the TS 26.092 comfort-noise tables used by the following commit: initial prediction residuals and LSP vector, LSF deviation scales, the mode-dependent level adjustment, and the DTX and excitation constants. - avcodec/amrwbdec: generate comfort noise for SID frames
Jun Zhao: A SID frame (frame type 9) returned AVERROR_PATCHWELCOME and was dropped, so a DTX stream lost 20 ms per SID frame.
Decode the 40-bit SID and follow the TS 26.173 DTX state machine in floating point: interpolate and mute between updates, then synthesize noise at the decoded energy. - avcodec/amrwbdata: add the comfort noise ISF codebooks
Jun Zhao: Add the five noise ISF codebooks and their mean vector from 3GPP TS 26.173 (qisf_ns.tab) for the SID decoder. - libavcodec: Add Infinity IMM6 Decoder
Tom Needham - ffplay: move the chapter list into its own file
Michael Niedermayer: The list becomes a ListView in ffplay_list.c, which shows entries with title, artist, length and metadata and reports the entry the user chooses; ffplay builds the entries from the chapters and seeks to the chosen one. - avfilter/vf_opencolorio: negotiate the output format properly
Sam.Richards@taurich.org: The filter picked its output format in config_props(), after format negotiation had already settled the output link.
Most Popular In The Past Month
- ffplay: show a list of the chapters on screen
Michael Niedermayer: Page up/down fade in a list of the chapters around the current one and fade it out again half a second after the last key press, "l" keeps it on screen, and while it is kept down/up move the selection. - lavf: add Panasonic RW2 image2 support
Lynne: Panasonic RW2 files decode as a single image through the image2 demuxer, recognised by the . - ffplay: sort the chapter list by clickable column buttons
Michael Niedermayer: Buttons above the list order it by chapter number, artist, title or duration. - swresample: skip the rematrix stage when there are no samples
Kacper Michajłow: When resampling first, a call that produced no output passed midbuf to swri_rematrix() before it was ever allocated, and copied channels did a memcpy() of zero bytes from NULL. - ffplay: make seek_chapter take the chapter index
Michael Niedermayer: The callers pass the index relative to the current chapter themselves, so the function can serve seeks to an arbitrary chapter too. - ffplay: filter the chapter list by typing while it is pinned
Michael Niedermayer: While the list is pinned it owns the keyboard: typed text narrows the entries to those whose artist or title contains it, backspace erases, escape closes the list. - lavc: add a Panasonic RW2 decoder
Lynne: Supports RawFormat 8, used by the S1II, S5II and GH6. - avfilter: drop the scale_npp filter source that is no longer needed
nyanmisaka: It should have been dropped in 9f58e30. - avfilter: add link negotiation for AVChromaLocation
Kacper Michajłow: Chroma sample location is the last of the video colorimetry properties without a negotiated link value, so nothing downstream can ask a filter for a particular siting and no encoder can constrain the graph. - avformat: add side data fields to Stream Groups
James Almer: Deprecate the Tile Grid specific ones, while keeping it in sync with the new fields until removed.