avfilter/vf_coreimage: use av_dict_iterate
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
1cf526c37a
commit
d5d6e5ccec
@ -416,8 +416,8 @@ static CIFilter* create_filter(CoreImageContext *ctx, const char *filter_name, A
|
|||||||
|
|
||||||
// set user options
|
// set user options
|
||||||
if (filter_options) {
|
if (filter_options) {
|
||||||
AVDictionaryEntry *o = NULL;
|
const AVDictionaryEntry *o = NULL;
|
||||||
while ((o = av_dict_get(filter_options, "", o, AV_DICT_IGNORE_SUFFIX))) {
|
while ((o = av_dict_iterate(filter_options, o))) {
|
||||||
set_option(ctx, filter, o->key, o->value);
|
set_option(ctx, filter, o->key, o->value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -427,10 +427,10 @@ static CIFilter* create_filter(CoreImageContext *ctx, const char *filter_name, A
|
|||||||
|
|
||||||
static av_cold int init(AVFilterContext *fctx)
|
static av_cold int init(AVFilterContext *fctx)
|
||||||
{
|
{
|
||||||
CoreImageContext *ctx = fctx->priv;
|
CoreImageContext *ctx = fctx->priv;
|
||||||
AVDictionary *filter_dict = NULL;
|
AVDictionary *filter_dict = NULL;
|
||||||
AVDictionaryEntry *f = NULL;
|
const AVDictionaryEntry *f = NULL;
|
||||||
AVDictionaryEntry *o = NULL;
|
const AVDictionaryEntry *o = NULL;
|
||||||
int ret;
|
int ret;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
@ -460,7 +460,7 @@ static av_cold int init(AVFilterContext *fctx)
|
|||||||
|
|
||||||
// parse filters for option key-value pairs (opt=val@opt2=val2) separated by @
|
// parse filters for option key-value pairs (opt=val@opt2=val2) separated by @
|
||||||
i = 0;
|
i = 0;
|
||||||
while ((f = av_dict_get(filter_dict, "", f, AV_DICT_IGNORE_SUFFIX))) {
|
while ((f = av_dict_iterate(filter_dict, f))) {
|
||||||
AVDictionary *filter_options = NULL;
|
AVDictionary *filter_options = NULL;
|
||||||
|
|
||||||
if (strncmp(f->value, "default", 7)) { // not default
|
if (strncmp(f->value, "default", 7)) { // not default
|
||||||
@ -477,7 +477,7 @@ static av_cold int init(AVFilterContext *fctx)
|
|||||||
if (!filter_options) {
|
if (!filter_options) {
|
||||||
av_log(ctx, AV_LOG_DEBUG, "\tusing default options\n");
|
av_log(ctx, AV_LOG_DEBUG, "\tusing default options\n");
|
||||||
} else {
|
} else {
|
||||||
while ((o = av_dict_get(filter_options, "", o, AV_DICT_IGNORE_SUFFIX))) {
|
while ((o = av_dict_iterate(filter_options, o))) {
|
||||||
av_log(ctx, AV_LOG_DEBUG, "\t%s: %s\n", o->key, o->value);
|
av_log(ctx, AV_LOG_DEBUG, "\t%s: %s\n", o->key, o->value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user