Showing the changes to libavfilter/avfilter.c (1 of 1 file). Show all
Unified · Split
| @@ -583,6 +583,7 @@ static void *filter_child_next(void *obj, void *prev) · 582 unmodified lines | ||
| 583 | 583 | return NULL; |
| 584 | 584 | } |
| 585 | 585 | |
| 586 | +#if FF_API_CHILD_CLASS_NEXT | |
| 586 | 587 | static const AVClass *filter_child_class_next(const AVClass *prev) |
| 587 | 588 | { |
| 588 | 589 | void *opaque = NULL; |
| @@ -604,6 +605,18 @@ static const AVClass *filter_child_class_next(const AVClass *prev) · 15 unmodified lines | ||
| 604 | 605 | |
| 605 | 606 | return NULL; |
| 606 | 607 | } |
| 608 | +#endif | |
| 609 | + | |
| 610 | +static const AVClass *filter_child_class_iterate(void **iter) | |
| 611 | +{ | |
| 612 | + const AVFilter *f; | |
| 613 | + | |
| 614 | + while ((f = av_filter_iterate(iter))) | |
| 615 | + if (f->priv_class) | |
| 616 | + return f->priv_class; | |
| 617 | + | |
| 618 | + return NULL; | |
| 619 | +} | |
| 607 | 620 | |
| 608 | 621 | #define OFFSET(x) offsetof(AVFilterContext, x) |
| 609 | 622 | #define FLAGS AV_OPT_FLAG_FILTERING_PARAM |
| @@ -625,7 +638,10 @@ static const AVClass avfilter_class = { · 15 unmodified lines | ||
| 625 | 638 | .version = LIBAVUTIL_VERSION_INT, |
| 626 | 639 | .category = AV_CLASS_CATEGORY_FILTER, |
| 627 | 640 | .child_next = filter_child_next, |
| 641 | +#if FF_API_CHILD_CLASS_NEXT | |
| 628 | 642 | .child_class_next = filter_child_class_next, |
| 643 | +#endif | |
| 644 | + .child_class_iterate = filter_child_class_iterate, | |
| 629 | 645 | .option = avfilter_options, |
| 630 | 646 | }; |
| 631 | 647 | |