This is an automated email from the git hooks/post-receive script.
Git pushed a commit to branch master
in repository ffmpeg.
The following commit(s) were added to refs/heads/master by this push:
new 6fdbb5a93e avfilter/dnn: fix missing set default value to options
6fdbb5a93e is described below
commit 6fdbb5a93e8e28d8b56540675b5e2c2347517b7a
Author: Zhao Zhili <[email protected]>
AuthorDate: Wed Mar 4 21:42:31 2026 +0800
Commit: Guo Yejun <[email protected]>
CommitDate: Fri Mar 6 21:41:11 2026 +0800
avfilter/dnn: fix missing set default value to options
There are two options which use non-zero default value: async and
batch_size of openvino. init_model_ov checks and set batch_size to
one when batch_size is equal to zero, so the only option affected
by missing default value is async. Now async works as expected.
---
libavfilter/dnn/dnn_interface.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libavfilter/dnn/dnn_interface.c b/libavfilter/dnn/dnn_interface.c
index c4e410756b..7080ab12e4 100644
--- a/libavfilter/dnn/dnn_interface.c
+++ b/libavfilter/dnn/dnn_interface.c
@@ -98,6 +98,8 @@ void ff_dnn_init_child_class(DnnContext *ctx)
for (int i = 0; i < FF_ARRAY_ELEMS(dnn_backend_info_list); i++) {
const AVClass **ptr = (const AVClass **) ((char *) ctx +
dnn_backend_info_list[i].offset);
*ptr = dnn_backend_info_list[i].class;
+ // Set default values after the class pointer is set
+ av_opt_set_defaults(ptr);
}
}
_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]