Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefan Westerfeld
ffmpeg
Commits
d4ae2a20
Commit
d4ae2a20
authored
Nov 12, 2021
by
Anton Khirnov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cmdutils: add an option for listing stream dispositions
parent
a4c5d241
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
0 deletions
+19
-0
fftools-common-opts.texi
doc/fftools-common-opts.texi
+3
-0
cmdutils.c
fftools/cmdutils.c
+10
-0
cmdutils.h
fftools/cmdutils.h
+6
-0
No files found.
doc/fftools-common-opts.texi
View file @
d4ae2a20
...
...
@@ -167,6 +167,9 @@ Show available sample formats.
@item -layouts
Show channel names and standard channel layouts.
@item -dispositions
Show stream dispositions.
@item -colors
Show recognized color names.
...
...
fftools/cmdutils.c
View file @
d4ae2a20
...
...
@@ -1820,6 +1820,16 @@ int show_sample_fmts(void *optctx, const char *opt, const char *arg)
return
0
;
}
int
show_dispositions
(
void
*
optctx
,
const
char
*
opt
,
const
char
*
arg
)
{
for
(
int
i
=
0
;
i
<
32
;
i
++
)
{
const
char
*
str
=
av_disposition_to_string
(
1
<<
i
);
if
(
str
)
printf
(
"%s
\n
"
,
str
);
}
return
0
;
}
static
void
show_help_codec
(
const
char
*
name
,
int
encoder
)
{
const
AVCodecDescriptor
*
desc
;
...
...
fftools/cmdutils.h
View file @
d4ae2a20
...
...
@@ -238,6 +238,7 @@ void show_help_options(const OptionDef *options, const char *msg, int req_flags,
{ "pix_fmts", OPT_EXIT, { .func_arg = show_pix_fmts }, "show available pixel formats" }, \
{ "layouts", OPT_EXIT, { .func_arg = show_layouts }, "show standard channel layouts" }, \
{ "sample_fmts", OPT_EXIT, { .func_arg = show_sample_fmts }, "show available audio sample formats" }, \
{ "dispositions", OPT_EXIT, { .func_arg = show_dispositions}, "show available stream dispositions" }, \
{ "colors", OPT_EXIT, { .func_arg = show_colors }, "show available color names" }, \
{ "loglevel", HAS_ARG, { .func_arg = opt_loglevel }, "set logging level", "loglevel" }, \
{ "v", HAS_ARG, { .func_arg = opt_loglevel }, "set logging level", "loglevel" }, \
...
...
@@ -577,6 +578,11 @@ int show_layouts(void *optctx, const char *opt, const char *arg);
*/
int
show_sample_fmts
(
void
*
optctx
,
const
char
*
opt
,
const
char
*
arg
);
/**
* Print a listing containing all supported stream dispositions.
*/
int
show_dispositions
(
void
*
optctx
,
const
char
*
opt
,
const
char
*
arg
);
/**
* Print a listing containing all the color names and values recognized
* by the program.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment