Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
8b994c8c
Commit
8b994c8c
authored
Mar 24, 2013
by
Clément Bœsch
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavfi/select: use standard options parsing.
parent
f7324c06
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
8 deletions
+4
-8
f_select.c
libavfilter/f_select.c
+4
-8
No files found.
libavfilter/f_select.c
View file @
8b994c8c
...
...
@@ -149,15 +149,8 @@ static const AVOption options[] = {
static
av_cold
int
init
(
AVFilterContext
*
ctx
,
const
char
*
args
,
const
AVClass
*
class
)
{
SelectContext
*
select
=
ctx
->
priv
;
const
char
*
shorthand
[]
=
{
"expr"
,
NULL
};
int
ret
;
select
->
class
=
class
;
av_opt_set_defaults
(
select
);
if
((
ret
=
av_opt_set_from_string
(
select
,
args
,
shorthand
,
"="
,
":"
))
<
0
)
return
ret
;
if
((
ret
=
av_expr_parse
(
&
select
->
expr
,
select
->
expr_str
,
var_names
,
NULL
,
NULL
,
NULL
,
NULL
,
0
,
ctx
))
<
0
)
{
av_log
(
ctx
,
AV_LOG_ERROR
,
"Error while parsing expression '%s'
\n
"
,
select
->
expr_str
);
...
...
@@ -373,7 +366,6 @@ static av_cold void uninit(AVFilterContext *ctx)
av_expr_free
(
select
->
expr
);
select
->
expr
=
NULL
;
av_opt_free
(
select
);
#if CONFIG_AVCODEC
if
(
select
->
do_scene_detect
)
{
...
...
@@ -402,6 +394,8 @@ static int query_formats(AVFilterContext *ctx)
return
0
;
}
static
const
char
*
const
shorthand
[]
=
{
"expr"
,
NULL
};
#if CONFIG_ASELECT_FILTER
#define aselect_options options
...
...
@@ -451,6 +445,7 @@ AVFilter avfilter_af_aselect = {
.
inputs
=
avfilter_af_aselect_inputs
,
.
outputs
=
avfilter_af_aselect_outputs
,
.
priv_class
=
&
aselect_class
,
.
shorthand
=
shorthand
,
};
#endif
/* CONFIG_ASELECT_FILTER */
...
...
@@ -507,5 +502,6 @@ AVFilter avfilter_vf_select = {
.
inputs
=
avfilter_vf_select_inputs
,
.
outputs
=
avfilter_vf_select_outputs
,
.
priv_class
=
&
select_class
,
.
shorthand
=
shorthand
,
};
#endif
/* CONFIG_SELECT_FILTER */
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