Commit Graph
100 Commits
Author SHA1 Message Date
Gyan Doshi 5ccd4d3060 ffmpeg: fix implementation of updated input start time
The current adjustment of input start times just adjusts the tsoffset.
And it does so, by resetting the tsoffset to nullify the new start time.
This leads to breakage of -copyts, ignoring of input_ts_offset, breaking
of -isync as well as breaking wrap correction.

Fixed by taking cognizance of these parameters, and by correcting start times
just before sync offsets are applied.
2022-11-03 14:38:42 +05:30
Gyan Doshi 93faba449c ffmpeg: shift start time correction to ffmpeg_opt
In preparation for applying start time correction that accounts for all
factors such as copyts, input_ts_offset ..etc
2022-11-03 14:38:24 +05:30
Gyan Doshi d5544f6457 ffprobe: restore reporting error code for failed inputs
c11fb46731 led to a regression whereby the return code for missing
input or input probe is overridden by writer close return code and
hence not conveyed in the exit code.
2022-08-17 16:46:05 +05:30
Gyan Doshi 9e029dc265 doc/filters: clarify behaviour of weights in amix 2022-08-09 13:59:29 +05:30
Gyan Doshi baf1f5dfb2 doc/filters: add examples for amix to subsection 2022-08-09 10:16:50 +05:30
Gyan Doshi 882aac99d2 ffmpeg: add option -isync
This is a per-file input option that adjusts an input's timestamps
with reference to another input, so that emitted packet timestamps
account for the difference between the start times of the two inputs.

Typical use case is to sync two or more live inputs such as from capture
devices. Both the target and reference input source timestamps should be
based on the same clock source.

If either input lacks starting timestamps, then no sync adjustment is made.
2022-07-14 15:48:24 +05:30
Gyan Doshi dba7376d59 doc/ffmpeg: correct description of -shortest
-shortest stops 'recording' when the shortest output stream ends. The
native or even seek-adjusted duration of the source input stream isn't
considered.
2022-07-04 14:43:48 +05:30
Gyan Doshi 0744c84792 avfilter/Makefile: always make colorspace.o
Unbreaks libavfilter builds when configured with a subset of filters.

drawutils added ff_draw_init2 in 6c3a82f043 which calls functions defined in
colorspace.c. So the latter needs to be built alongside the former.
2022-06-25 17:55:53 +05:30
Gyan Doshi 56419428a8 avcodec/mfenc: set variable frame size flag.
Default avctx->frame_size is 0 which led to init failure for
audio MediaFoundation encoders since 827d6fe73d.

The MF audio encoders accept variable frame size input buffers.

Fixes #9802
2022-06-20 15:04:26 +05:30
Gyan Doshi 557a1a8af2 doc/APIchanges: add missing marker for release 5.0 2022-06-16 12:52:24 +05:30
Gyan Doshi 09c53a04c5 ffmpeg: add option fps_mode
fps_mode sets video sync per output stream. Overrides vsync for matching
streams.

vsync is deprecated.
2022-06-11 09:47:27 +05:30
Gyan Doshi 0dcbe1c1aa doc/protocols: add details and reformat IPFS section 2022-05-26 16:21:28 +05:30
Gyan Doshi 8a0f7f7bfe doc/protocols: sort IPFS section alphabetically 2022-05-26 16:20:49 +05:30
Gyan Doshi 9ab20b1614 opt_common: note D and T type streams for completeness.
Addresses #9784
2022-05-20 23:42:23 +05:30
Gyan Doshi 00ae20dfb4 doc/muxers: note write_btrt option for MOV/MP4 2022-05-16 13:56:38 +05:30
Gyan Doshi 8b64d8d9aa avformat/dashdec: accept and relay CENC decryption key
Allows to process CENC-encrypted media segments.
Option arg syntax is same as that for option decryption_key in MOV demuxer
2022-05-14 14:46:01 +05:30
Gyan Doshi b980d9e8ec avfilter/geq: unbreak alpha processing
d607af50fd broke alpha processing by always overwriting any supplied
alpha expression.
2022-05-08 10:05:19 +05:30
Gyan Doshi 1405b65d22 avfilter/lensfun: add option db_path
The lensfun filter, at present, loads its database from a path hardcoded
at build time. This may not be known or available to end users.

Added option db_path allows custom path.
2022-04-12 15:20:10 +05:30
Gyan Doshi d6d46a2c50 doc/filters: guide to list lensfun db emtries 2022-04-11 16:15:22 +05:30
Gyan Doshi 607ecc27ed doc/filters: add range/defaults for tile filter options 2022-04-07 15:56:43 +05:30
Gyan Doshi fa12d808d7 doc/encoders: update libwebpenc quality option
A private encoder option 'quality' was added in 716674b151, making
the doc entry obsolete.
2022-03-24 17:33:00 +05:30
Gyan Doshi 505a7d39cd doc/bitstream_filters: add missing options in h264_metadata 2022-03-21 16:00:02 +05:30
Gyan Doshi 72684d2c2d doc/filters: correct default value of lut filters 2022-03-03 16:48:33 +05:30
Gyan Doshi 4b72bca6ca avfilter/drawtext: change reload value to an interval
Allows user to specify a frame interval at which textfile is reloaded.
2022-03-02 12:56:58 +05:30
Gyan Doshi 8ef03c2ff1 doc/muxers: note video_track_timecale in mov 2022-02-24 16:11:26 +05:30
Gyan Doshi 2812508086 doc/muxers: add entry for empty_hdlr_name in mov 2022-02-17 16:11:16 +05:30
Gyan Doshi b6bb6b9f22 avformat/mpegts: initialize max_packet_size when sub-demuxer
bca30570d2 added a user option to set max_packet_size replacing
a hardcoded value. This had a side-effect of leaving the field
set to 0 when packet demuxing is carried out from another demuxer
using avpriv functions, which could lead to demux failure.

Hardcoded max_packet_size inside avpriv_mpegts_parse_open to
2048000 to avoid this. Value chosen to be 10x that of default value
to accommodate large payloads.
2022-02-10 16:57:59 +05:30
Gyan Doshi e1a14479a8 ffprobe: allow side-data selection by element
At present, side data printing forces display for all levels i.e.
stream, packets and frames. This can bloat output and also force
decode of all frames in selected streams.

Now, stream_side_data[=type], packet_side_data[=type] &
frame_side_data[=type] can be used with -show_entries to specify carrier
element.
2022-02-03 16:04:24 +05:30
Gyan Doshi b635ac126f doc/filters: note format constraint for volumedetect 2022-01-24 09:51:07 +05:30
Gyan Doshi bca30570d2 avformat/mpegts: add option max_packet_size
Makes maximum size of emitted packet user-tunable.

Default is existing 204800 bytes.
2022-01-16 10:46:38 +05:30
Gyan Doshi 1850c610e7 avformat/hlsenc: convey stream id to segment streams 2022-01-09 10:37:00 +05:30
Gyan Doshi 2f6360ff21 configure: bump year 2022-01-01 00:29:41 +05:30
Gyan Doshi 9cfc7a2440 avformat/mov: add option max_stts_delta
Very high stts sample deltas may occasionally be intended but usually
they are written in error or used to store a negative value for dts correction
when treated as signed 32-bit integers.

This option lets the user set an upper limit, beyond which the delta is clamped to 1.
Values greater than the limit if negative when cast to int32 are used to adjust onward dts.

Unit is the track time scale. Default is UINT_MAX - 48000*10 which
allows upto a 10 second dts correction for 48 kHz audio streams while
accommodating 99.9% of uint32 range.

Signed-off-by: Gyan Doshi <ffmpeg@gyani.pro>
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
2021-12-31 14:44:20 +05:30
Gyan Doshi 12f21849e5 doc/demuxers: add entry for aac 2021-12-30 17:10:30 +05:30
Gyan Doshi a454dfacd5 avformat/concatf: ignore trailing whitespaces
The concatf protocol returns an opaque error on open if
concatf list file contains trailing newlines.

Signed-off-by: Gyan Doshi <ffmpeg@gyani.pro>
Reviewed-by: James Almer <jamrial@gmail.com>
2021-12-07 17:50:55 +05:30
Gyan Doshi ef00d40e32 doc/filters: note duration range in xfade 2021-12-06 16:35:47 +05:30
Gyan Doshi 203b0e3561 avformat/mov: make STTS duration unsigned int
As per 8.6.1.2.2 of ISO/IEC 14496-12:2015(E), STTS sample offsets
are to be always stored as uint32_t. So far, they have been signed ints
which led to desync in files with very large offsets.

The MOVStts struct was used to store CTTS offsets as well. These can be
negative in version 1. So a new struct MOVCtts was created and all
declarations for CTTS usage changed to MOVCtts.
2021-11-22 15:18:42 +05:30
Gyan Doshi 9e8cdb24cd doc/filters: add details and ranges for colorkey 2021-11-15 17:16:56 +05:30
Gyan Doshi 2aa343bb6f doc/filters: add notes for varblur 2021-10-21 16:13:54 +05:30
Gyan Doshi d04c005021 doc/filters: correct description of select filter variables 2021-10-18 14:28:04 +05:30
Gyan Doshi f79be02be0 README: fix typo and description of libavfilter
Thanks to Arif Driessen for bringing notice to the typo.
2021-10-08 09:44:34 +05:30
Gyan Doshi a947098558 doc/muxers: add entry for OBU muxer 2021-09-05 16:01:02 +05:30
Gyan Doshi d905af0c24 avformat/mov: add AVFMT_SHOW_IDS flag
The MOV muxer can store streamids as track ids but they aren't
visible when probing the result via lavf/dump or ffprobe due to
lack of this flag in the demuxer.
2021-08-22 17:55:31 +05:30
Gyan Doshi c50f5460d2 ffmpeg_opt: restore documented stream selection behaviour
11d3b03fcb added consideration of default stream disposition for audio
and video when choosing the 'best' stream among all the inputs. This can
lead to video streams with lower resolution or audio streams with fewer
channels being selected.

Stream disposition, however, only sets a priority for a stream
among all other streams in the *same input*. It cannot set a priority
for a stream across all inputs.

This patch sets a middle-way and selects the best stream from each file
with default disposition considered. Then it discards disposition weight
and selects best stream as per the original criteria of highest
resolution for video and most channels for audio.
2021-08-01 09:51:07 +05:30
Gyan Doshi b9176dbfb7 avcodec/noise_bsf: restore dropamount for backwards compatibility 2021-07-30 17:14:43 +05:30
Gyan Doshi 23da5caf09 avcodec/noise_bsf: add expr support 2021-07-29 22:05:11 +05:30
Gyan Doshi f614390ecc doc/filters: note expr and eval mode support in overlay_cuda
Commit 58c908cf94 added support for expressions for x and y parameters.
Also added was option to set eval frequency.
2021-07-21 13:08:13 +05:30
Gyan Doshi cd7043131f avformat/gifdec: log loop count 2021-07-20 11:20:04 +05:30
Gyan Doshi 6f20685228 ffmpeg: delay readrate enforcement for decoded streams
Read rate enforcement delayed till first decoded frame is obtained, to
speed up init of output streams.

Thanks to Linjie Fu <linjie.justin.fu@gmail.com> for the initial patch.
2021-07-19 12:54:55 +05:30
Gyan Doshi c320b78e95 ffmpeg: add option readrate
Allows to read inputs at arbitrary rates.
-re is equivalent to -readrate 1

Tested with -copyts {+ start_at_zero}, -ss, streamcopied & decoded streams.
2021-07-17 20:34:21 +05:30
Gyan Doshi 1aa9dcd091 avcodec/qsvenc: clip global_quality for ICQ modes.
Allowed range is 1 to 51.

Ref: https://software.intel.com/content/www/us/en/develop/articles/advanced-bitrate-control-methods-in-intel-media-sdk.html
2021-07-12 09:33:22 +05:30
Gyan Doshi 79ebdbb9b9 ffmpeg: add option recast_media
Allows forcing decoders of different media type.
Needed to decode media data muxed as data streams.
2021-07-11 11:54:20 +05:30
Gyan Doshi b7ba472f43 avfilter/fps: remove unconventional acronyms
In dd770883e9, support for expressions was added. Among the constants
added were labels of qnstc, qpal, sntsc & spal.

These were added in ba2a8cb40b to represent parameter permutations where
only the resolution is different. They don't have any usage currency and
don't represent any industry standards or convention in terms of framerate.
2021-07-06 11:43:31 +05:30
Gyan Doshi 301d275301 avcodec/bsf: switch to av_get_token to parse bsf list string
The recently added setts bsf makes use of the eval API whose
expressions can contain commas. The existing parsing in
av_bsf_list_parse_str() uses av_strtok to naively split
the string at commas, thus preventing the use of setts filter
with expressions containing commas.

av_get_token can work with escaped commas, allowing full use of setts.
2021-07-04 09:54:33 +05:30
Gyan Doshi de8e6e67e7 doc/muxers: note atomic_writing in image2
Fixes #9308
2021-06-30 09:34:09 +05:30
Gyan Doshi 49e3a8165c doc/filters: mention availability of mcdeint, uspp
Filters are present in tree of master and in docs but were
hard-disabled in 95054bfa48.
They remain available in v4.4 or earlier.
2021-06-27 15:40:37 +05:30
Gyan Doshi 604924a069 doc/filters: document expr support in fps filter
Added in dd770883e9
2021-06-16 15:43:10 +05:30
Gyan Doshi 3ce272a9da doc/demuxers: note defaults for apng options 2021-06-13 17:07:37 +05:30
Gyan Doshi 99bbf4a5be doc/ffmpeg: document reinit_filter 2021-06-10 09:57:18 +05:30
Gyan Doshi 071930de72 avformat/mov: add option to use tfdt for fragment timestamps. 2021-06-02 10:46:04 +05:30
Gyan Doshi 51f1194eda avformat/hls: relay format options to segment demuxer
Signed-off-by: Gyan Doshi <ffmpeg@gyani.pro>
Reviewed-by: Steven Liu <lq@chinaffmpeg.org>
2021-05-30 09:21:19 +05:30
Gyan Doshi 4c0d6c91f6 doc/encoders: update default coder for aac
Changed in 660d1d8e3b.
2021-05-23 13:30:44 +05:30
Gyan Doshi 2261cc6d8a doc/filters: note order of inputs for libvmaf 2021-05-19 14:50:00 +05:30
Gyan Doshi f53414a038 avfilter/metadata: add intuitive labels for metadata values 2021-05-16 10:24:27 +05:30
Gyan Doshi 37099f2132 doc/filters: Unhedge note for sub option in guided filter 2021-05-14 15:39:47 +05:30
Gyan Doshi 234e719194 avfilter/guided: reindent after 93ddb9b617 2021-05-14 15:37:45 +05:30
Gyan Doshi 93ddb9b617 avfilter/guided: simplify subsampling assignment.
Reduce option ranges to effective values.

Signed-off-by: Gyan Doshi <ffmpeg@gyani.pro>
Reviewed-by: Steven Liu <liuqi05@kuaishou.com>
2021-05-14 15:33:30 +05:30
Gyan Doshi c122a6c10d doc/filters: correct name for guided filter
Note input requirements and reword option sub description.
2021-05-13 19:06:56 +05:30
Gyan Doshi 8649f5dca6 doc/muxers: note movie_timescale option in movenc 2021-05-09 15:03:39 +05:30
Gyan Doshi 8ab2bb81b2 avformat/hlsenc: correct log text and supply packet details 2021-05-05 20:26:38 +05:30
Gyan Doshi 7c451b609c ffprobe: add option to control optional fields display 2021-05-05 15:04:54 +05:30
Gyan Doshi b06082d1d5 avformat/dtsenc: reindent 2021-04-27 09:21:43 +05:30
Gyan Doshi 45fc214ebf avformat/adtsenc: clarify option help
Also remove unnecessary unit as option does not accept any constants.
2021-04-27 09:18:41 +05:30
Gyan Doshi d57104e698 doc/muxers: add entry for ALP muxer 2021-04-26 19:22:50 +05:30
Gyan Doshi 343d54a733 doc/muxers: add entry for ADTS muxer 2021-04-26 16:43:38 +05:30
Gyan Doshi 54d8386f52 doc/filters: note requirements for xfade inputs 2021-04-20 09:32:50 +05:30
Gyan Doshi 240aa70b79 avformat/rawenc: remove singlejpeg muxer
It was added in 51ac1f616f due to ticket #4218, in order to show a single
image via ffserver. With ffserver long gone, it serves no purpose.
2021-04-16 11:14:36 +05:30
Gyan Doshi 309e3cc15c avformat/rawenc: perform stream checks for mp2 muxer 2021-04-11 16:46:08 +05:30
Gyan Doshi 47b8871ca6 doc/muxers: add entries for raw muxers 2021-04-11 12:09:16 +05:30
Gyan Doshi c06465a70b doc/muxers: fix alphabetical sorting of entries 2021-04-07 14:45:03 +05:30
Gyan Doshi 18dcbb0d6c avfilter/find_rect: write score to metadata 2021-04-04 10:47:13 +05:30
Gyan Doshi abdafca9ad avfilter/find_rect: add option to discard non-matching frames
Default is disabled.
2021-04-04 10:47:09 +05:30
Gyan Doshi aff23c3474 avfilter/find_rect: improve logging
Log now indicates timestamps of frames where a match is made.
Loglevel is changed to INFO since the user specifically wants this info.
2021-04-04 10:46:57 +05:30
Gyan Doshi 090dc381a1 doc/ffmpeg: clarify what -hwaccels list indicates
Fixes #8204
2021-04-03 10:58:07 +05:30
Gyan Doshi 3d97a0061c doc/muxers: add entry for A64 muxer 2021-04-02 15:21:32 +05:30
Gyan Doshi a3f695d54b doc/encoders: add entry for a64 encoders 2021-04-02 15:20:14 +05:30
Gyan Doshi eac77f7cf0 rtpenc_mpegts: add AVClass to the muxer context 2021-04-01 09:34:58 +05:30
Gyan Doshi 61ea0e3191 doc/demuxers: note support for flv variant KUX 2021-03-31 15:16:12 +05:30
Gyan Doshi 8b2bde0494 avformat/rtpenc_mpegts: stop leaks
Fixes CID 1474460 & 1474461
2021-03-28 15:55:02 +05:30
Gyan Doshi 1d1a96acf5 doc/filters: note default for elbg pal8 option 2021-03-28 15:26:56 +05:30
Gyan Doshi 2c806aa2b4 avformat/rtpenc_mpegts: convey options for rtp muxer 2021-03-26 12:37:10 +05:30
Gyan Doshi 325bb04188 avformat/rtpenc_mpegts: relay streamid to mpegts muxer streams. 2021-03-26 12:35:37 +05:30
Gyan Doshi affe911c65 avformat/rtpenc_mpegts: convey options for mpeg-ts muxer
Fixes #5239
2021-03-26 12:34:27 +05:30
Gyan Doshi 322be6107a doc/filters: fix option name for mix filter
Corrected from nb_inputs to inputs
2021-03-24 16:52:02 +05:30
Gyan Doshi 75fd3e1519 avformat/rtp_mpegts: typedef MuxChain struct 2021-03-21 15:50:40 +05:30
Gyan Doshi 36a5ae619a configure: select child muxers for rtp_mpegts 2021-03-21 15:50:23 +05:30
Gyan Doshi c5341d415c doc/filters: remove option band in delogo
Deprecated option removed in 74fe697f96 but I forgot to remove
the docs entry.
2021-03-19 17:21:03 +05:30
Gyan Doshi 3a79ab8317 doc/ffmpeg: document parameters set by -target 2021-03-19 17:00:17 +05:30
Gyan DoshiandTimo Rothenpieler 434b626b7a avcodec/libdavs2: unbreak compilation failure
FF_CODEC_CAP_AUTO_THREADS added in 8a129077cc requires internal.h

Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
2021-03-17 14:36:13 +01:00
Gyan Doshi 1d61a31497 doc/filters: note default for zoompan's duration 2021-03-14 14:07:24 +05:30