Opened 3 years ago
Closed 3 years ago
#6906 closed defect (fixed)
Re-order options for testsrc family of filters in manual
Reported by: | Misaki | Owned by: | |
---|---|---|---|
Priority: | minor | Component: | documentation |
Version: | git-master | Keywords: | testsrc |
Cc: | Blocked By: | ||
Blocking: | Reproduced by developer: | no | |
Analyzed by developer: | no |
Description
According to the manual, option four for filter 'color' should be sample aspect ratio: https://ffmpeg.org/ffmpeg-filters.html
However, the command ffmpeg -filter_complex "color=white:160x160:1:1:10" output.mp4 produces output of 1 frame.
Change History (5)
comment:1 Changed 3 years ago by Misaki
- Component changed from avfilter to undetermined
comment:2 in reply to: ↑ description Changed 3 years ago by cehoyos
comment:3 Changed 3 years ago by llogan
- Component changed from undetermined to documentation
- Keywords testsrc added
- Status changed from new to open
- Summary changed from Option order wrong for filter 'color' to Re-order options for testsrc family of filters in manual
Don't rely on shorthand: it can be ambiguous or confusing and lead to mistakes, and there may be no guarantee that the order will always remain the same. Include the option names with your values: color=c=white:s=160x160:r=1:d=10:sar=1.
The manual entry is an unorganized combination for the color and other related testsrc based source filters, so trying to count the position of each supported option (and excluding the options specific to the other filters) is not recommended. If you must use shortcuts then refer to ffmpeg -h filter=color instead. As you can see from this output sar is currently option five.
To address this the order in the manual can be changed to: level, c, s, r, d, sar, alpha, n. I did not check the order of other non-testsrc filters. To check them all is arguably a "wontfix" ticket out of pure laziness because reviewing each filter is going to be a boring, mindless job as there are at least 350 filters I estimate, and filter authors may not sync the option order in future filters. Patch welcome!
Your output is one frame because you told it to make a frame rate of 1 and a duration of 1 second.
comment:4 Changed 3 years ago by llogan
- Version changed from unspecified to git-master
comment:5 Changed 3 years ago by llogan
- Resolution set to fixed
- Status changed from open to closed
Fixed in 555119bd762540a9f17a61bdd92329c8b8feb1e0.
Replying to Misaki:
Where is this specified?