Commit Graph

9158 Commits

Author SHA1 Message Date
Niklas Haas df868bae23 doc/filters: mention scale2ref in replacement example
So ctrl+f "scale2ref" finds it.
2024-05-04 13:15:15 +02:00
Niklas Haas 8bf0a9c2ca doc/filters: move scale=ref_* to correct sectton
This was accidentally filed under scale_npp, instead of scale. (Why is
this entire section basically duplicated anyway?)
2024-05-04 13:15:11 +02:00
Niklas Haas 95568c4e31 avfilter/scale2ref: deprecate in favor of scale=rw:rh
And remove it from the documentation.
2024-05-03 14:23:23 +02:00
Niklas Haas bb80445813 avfilter/vf_scale: add optional "ref" input
This is automatically enabled if the width/height expressions reference
any ref_* variable. This will ultimately serve as a more principled
replacement for the fundamentally broken scale2ref.

See-Also: https://trac.ffmpeg.org/ticket/10795
2024-05-03 14:23:23 +02:00
Niklas Haas e82a3997cd avfilter/vf_scale: switch to FFFrameSync
Preliminary commit, in anticipation of adding support for multiple
inputs (with proper synchronization and activate() callback).
2024-05-03 14:23:23 +02:00
Derek Buitenhuis 2d5fa816fb avformat/http: Add support for Retry-After header
429 and 503 codes can, and often do (e.g. all Google Cloud
Storage URLs can), return a Retry-After header with the error,
indicating how long to wait, asd either a date, or in seconds,
before retrying again. If it is not respected by, for example,
using our default backoff stratetgy instead, chances of success
are very unlikely.

Some references:
    * https://datatracker.ietf.org/doc/html/rfc6585
    * https://datatracker.ietf.org/doc/html/rfc7231#section-7.1.3

This adds an AVOption to respect that header.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2024-04-25 15:21:25 +01:00
Derek Buitenhuis 1f8e5b6d95 doc/protocols: Fill in missing HTTP options
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2024-04-25 14:21:25 +01:00
Derek Buitenhuis 5d568b16a0 doc/protocols: Re-order HTTP options to match http.c order
This makes the list easier to maintain.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2024-04-25 14:20:28 +01:00
Michael Niedermayer cae0f2bc55
doc/examples/qsv_transcode: Initialize pointer before free
Fixees: CID1517023 Uninitialized pointer read

Sponsored-by: Sovereign Tech Fund
Reviewed-by: "Xiang, Haihao" <haihao.xiang@intel.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-25 03:24:59 +02:00
Michael Niedermayer 191950d1bf
doc/examples/qsv_transcode: Simplify str_to_dict() loop
Fixes: CID1517022 Logically dead code

Sponsored-by: Sovereign Tech Fund
Reviewed-by: "Xiang, Haihao" <haihao.xiang@intel.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-25 03:24:59 +02:00
Michael Niedermayer c9c11a0866
doc/examples/vaapi_transcode: Simplify loop
Fixes: CID1428858(1/2) Logically dead code

Sponsored-by: Sovereign Tech Fund
Reviewed-by: "mypopy@gmail.com" <mypopy@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-25 03:24:58 +02:00
Michael Niedermayer 82cce20934
doc/examples/qsv_transcode: Simplify loop
Fixes: CID1428858(2/2) Logically dead code

Sponsored-by: Sovereign Tech Fund
Reviewed-by: "Xiang, Haihao" <haihao.xiang@intel.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-25 03:24:58 +02:00
James Almer 725d3b6f17 doc/APIchanges: fix date for the latest entry
And add the commit hash while at it.

Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-24 00:19:36 -03:00
James Almer ecf87dd230 fftools/ffmpeg_mux_init: allow mapping a stream group from one of the inputs
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-23 23:54:46 -03:00
James Almer 8616cfe089 avutil/opt: add support for children objects in av_opt_serialize
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-23 23:54:46 -03:00
Timo Rothenpieler 61f27e5f71 doc: use HOSTEXESUF when calling print_options
This is neccesary on WSL, and has no averse effects in normal
environments.
2024-04-24 00:09:38 +02:00
Andreas Rheinhardt 2b46ae6407 avcodec/codec_internal: Remove FF_CODEC_CAP_ALLOCATE_PROGRESS
Before commit f025b8e110,
every frame-threaded decoder used ThreadFrames, even when
they did not have any inter-frame dependencies at all.
In order to distinguish those decoders that need the AVBuffer
for progress communication from those that do not (to avoid
the allocation for the latter), the former decoders were marked
with the FF_CODEC_CAP_ALLOCATE_PROGRESS internal codec cap.

Yet distinguishing these two can be done in a more natural way:
Don't use ThreadFrames when not needed and split ff_thread_get_buffer()
into a core function that calls the user's get_buffer2 callback
and a wrapper around it that also allocates the progress AVBuffer.
This has been done in 02220b88fc
and since that commit the ALLOCATE_PROGRESS cap was nearly redundant.

The only exception was WebP and VP8. WebP can contain VP8
and uses the VP8 decoder directly (i.e. they share the same
AVCodecContext). Both decoders are frame-threaded and VP8
has inter-frame dependencies (in general, not in valid WebP)
and therefore the ALLOCATE_PROGRESS cap. In order to avoid
allocating progress in case of a frame-threaded WebP decoder
the cap and the check for the cap has been kept in place.

Yet now the VP8 decoder has been switched to use ProgressFrames
and therefore there is just no reason any more for this check
and the cap. This commit therefore removes both.

Also change the value of FF_CODEC_CAP_USES_PROGRESSFRAMES
to leave no gaps.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2024-04-19 13:18:04 +02:00
Stefano Sabatini 0fb0946de7 doc/muxers: add mmf 2024-04-19 09:00:59 +02:00
Stefano Sabatini b9f2e1b929 doc/muxers: add microdvd 2024-04-19 09:00:59 +02:00
Stefano Sabatini ac3460c61c doc/muxers/md5: apply misc consistency fixes 2024-04-19 09:00:41 +02:00
Stefano Sabatini 4bd192ddf4 doc/muxers/matroska: add missing options, apply misc style fixes 2024-04-19 08:44:20 +02:00
Xinpeng Sun 35ae44c615 lavfi/tonemap_vaapi: Add support for HDR to HDR tone mapping
Usage example:
ffmpeg -y -hwaccel vaapi -hwaccel_output_format vaapi -i hdr.mp4 \
-vf "tonemap_vaapi=display=7500 3000|34000 16000|13250 34500|15635 16450|500 10000000:extra_hw_frames=64" \
-c:v hevc_vaapi output.mp4

Signed-off-by: Xinpeng Sun <xinpeng.sun@intel.com>
Signed-off-by: Haihao Xiang <haihao.xiang@intel.com>
2024-04-18 14:43:07 +08:00
Haihao Xiang 3172a6722e lavfi/tonemap_vaapi: By default use bt709 for output frame
By default don't use the color properties from input frame as output
frame properties when performing HDR to SDR conversion

Signed-off-by: Haihao Xiang <haihao.xiang@intel.com>
2024-04-18 14:43:07 +08:00
Haihao Xiang 5c55e4e297 lavfi: Add drawbox_vaapi filter
Signed-off-by: Haihao Xiang <haihao.xiang@intel.com>
2024-04-18 14:43:07 +08:00
Haihao Xiang 42eb10ecc6 lavfi: Add pad_vaapi filter
Signed-off-by: Haihao Xiang <haihao.xiang@intel.com>
2024-04-18 14:43:07 +08:00
Antoine SOULIER 257bc2a82a avformat/lc3: add file format for LC3/LC3plus transport
A file format is described in Bluetooth SIG LC3 and ETSI TS 103 634, for
test purpose.
2024-04-15 18:34:12 +02:00
Stefano Sabatini b2bc4ac69e doc/utils/eval: review and extend, clarify ld/st index meaning
Prefer idx in place of id for functions accessing the internal
variables, and add a short introduction to mention them.
2024-04-15 18:32:38 +02:00
Stefano Sabatini 8ceb37d5ad doc/utils/eval: clarify meaning of random* seed value
Possible address trac issue:
http://trac.ffmpeg.org/ticket/10763
2024-04-15 18:30:35 +02:00
Andreas Rheinhardt f48987f609 doc/muxers.texi: Don't use confusing variable name
reserve_index_space is a size, not an index.
Also refer to the variable in the description.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2024-04-14 17:25:16 +02:00
James Almer 6d0c89980c avcodec/hevcdec: export global side data in AVCodecContext
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-11 11:48:39 -03:00
James Almer 6d760c666d avutil/mastering_display_metadata: add a new allocator function that returns a size
av_mastering_display_metadata_alloc() is not useful in scenarios where you need to
know the runtime size of AVMasteringDisplayMetadata.

Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-11 11:46:18 -03:00
James Almer adb67bba06 avutil/version: bump minor after recent AVFrame API additions
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-11 11:43:51 -03:00
Andreas Rheinhardt fee093a570 avcodec/ac3enc: Remove disabled code for RealAudio variant of AC-3
Implicitly disabled by 4679a474f0.
Given that no one has ever complained about this, this commit
removes the now dead code.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2024-04-11 12:52:46 +02:00
Stefano Sabatini 7e59c4f908 doc/muxers/matroska: apply misc consistency fixups 2024-04-10 10:56:54 +02:00
Stefano Sabatini 8510108c1d doc/muxers: add lrc 2024-04-10 10:56:54 +02:00
Stefano Sabatini 57d64bb715 doc/muxers: add kvag 2024-04-10 10:56:54 +02:00
Stefano Sabatini f7fd228560 doc/muxers: add jacosub 2024-04-10 10:56:54 +02:00
Stefano Sabatini 4fe3c8dcfd doc/muxers: add ivf 2024-04-10 10:56:54 +02:00
J. Dekker 67e2f8b6bf configure, etc: switch to shebang without space
Note that the config.sh file is left without a shebang, this file is
supposed to be sourced into the current environment.

This commit is purely cosmetic.

Signed-off-by: J. Dekker <jdek@itanimul.li>
2024-04-09 16:01:24 +02:00
Anton Khirnov baf17c15be doc/ffmpeg: document that there can be multiple complex filtergraphs 2024-04-09 10:34:18 +02:00
Anton Khirnov 3bd7c57125 fftools/ffmpeg_filter: implement filtergraph chaining
This allows one complex filtergraph's output to be sent as input to
another one, which is useful in certain situations (one is described in
the docs).

Chaining filtergraphs was already effectively possible by using a
wrapped_avframe encoder connected to a loopback decoder, but it is ugly,
non-obvious and inefficient.
2024-04-09 10:34:18 +02:00
James Almer 6f13f5dd59 doc/encoders: add missing libxvid option
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-05 17:20:54 -03:00
James Almer 16ba7bdd76 doc/encoders: remove non-existent flag
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-05 17:13:15 -03:00
Antoine Soulier via ffmpeg-devel 240fd04db2 avcodec/liblc3: add encoding/decoding support of LC3 audio codec
The LC3 audio codec is the default codec of Bluetooth LE audio.
This is a wrapper over the liblc3 library (https://github.com/google/liblc3).

Signed-off-by: Antoine Soulier <asoulier@google.com>
2024-04-04 17:47:31 +02:00
Michael Niedermayer 5a5422196d
doc/developer: (security) researchers should be credited
Reviewed-by: Tomas Härdin <git@haerdin.se>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-03 21:38:24 +02:00
Jan Ekström 29561c8e2d avutil/pix{desc,fmt}: add new matrix coefficients from H.273 v3
* SMPTE ST 2128 IPT-C2 defines the coefficients utilized in DoVi
  Profile 5. Profile 5 can thus now be represented in VUI as
  {AVCOL_RANGE_JPEG, AVCOL_PRI_BT2020, AVCOL_TRC_SMPTE2084,
   AVCOL_SPC_IPT_C2, AVCHROMA_LOC_LEFT} (although other chroma
  sample locations are allowed). AVCOL_TRC_SMPTE2084 should in
  this case be interpreted as 'PQ with reshaping'.
* YCgCo-Re and YCgCo-Ro define the bitexact YCgCo-R, where the
  number of bits added to a source RGB bit depth is 2 (i.e., even)
  and 1 (i.e., odd), respectively.
2024-04-03 21:31:35 +03:00
Niklas Haas 4f55e16f2b avutil/dovi_meta: add dolby vision extension blocks
As well as accessors plus a function for allocating this struct with
extension blocks,

Definitions generously taken from quietvoid/dovi_tool, which is
assembled as a collection of various patent fragments, as well as output
by the official Dolby Vision bitstream verifier tool.
2024-04-03 16:16:25 +02:00
quietvoid 78076ede29 avutil/dovi_meta: add AVDOVIDataMapping.nlq_pivots
The NLQ pivots are not documented but should be present in the header
for profile 7 RPU format. It has been verified using Dolby's
verification toolkit.

Signed-off-by: quietvoid <tcChlisop0@gmail.com>
Signed-off-by: Niklas Haas <git@haasn.dev>
2024-04-03 16:16:23 +02:00
Marth64 2204ea00d6 doc/indevs: update CC extraction example to use RCWT muxer
Signed-off-by: Marth64 <marth64@proxyid.net>
2024-04-02 20:09:05 +02:00
Marth64 0866b2ba5e doc/muxers: refresh the RCWT muxer's doc to be consistent with the demuxer
Signed-off-by: Marth64 <marth64@proxyid.net>
2024-04-02 20:09:05 +02:00