Removes an arbitrary hardcoded limit on the number of filters.
Showing the changes to libavfilter/avfilter.h (1 of 7 files). Show all
Unified · Split
| @@ -457,6 +457,8 @@ typedef struct AVFilter { · 456 unmodified lines | ||
| 457 | 457 | int (*query_formats)(AVFilterContext *); |
| 458 | 458 | |
| 459 | 459 | int priv_size; ///< size of private data to allocate for the filter |
| 460 | + | |
| 461 | + struct AVFilter *next; | |
| 460 | 462 | } AVFilter; |
| 461 | 463 | |
| 462 | 464 | /** An instance of a filter */ |
| @@ -622,8 +624,11 @@ AVFilterBufferRef *avfilter_get_audio_buffer_ref_from_arrays(uint8_t **data, · 159 unmodified lines | ||
| 622 | 624 | /** Initialize the filter system. Register all builtin filters. */ |
| 623 | 625 | void avfilter_register_all(void); |
| 624 | 626 | |
| 627 | +#if FF_API_OLD_FILTER_REGISTER | |
| 625 | 628 | /** Uninitialize the filter system. Unregister all filters. */ |
| 629 | +attribute_deprecated | |
| 626 | 630 | void avfilter_uninit(void); |
| 631 | +#endif | |
| 627 | 632 | |
| 628 | 633 | /** |
| 629 | 634 | * Register a filter. This is only needed if you plan to use |
| @@ -646,13 +651,24 @@ int avfilter_register(AVFilter *filter); · 16 unmodified lines | ||
| 646 | 651 | */ |
| 647 | 652 | AVFilter *avfilter_get_by_name(const char *name); |
| 648 | 653 | |
| 654 | +/** | |
| 655 | + * Iterate over all registered filters. | |
| 656 | + * @return If prev is non-NULL, next registered filter after prev or NULL if | |
| 657 | + * prev is the last filter. If prev is NULL, return the first registered filter. | |
| 658 | + */ | |
| 659 | +const AVFilter *avfilter_next(const AVFilter *prev); | |
| 660 | + | |
| 661 | +#if FF_API_OLD_FILTER_REGISTER | |
| 649 | 662 | /** |
| 650 | 663 | * If filter is NULL, returns a pointer to the first registered filter pointer, |
| 651 | 664 | * if filter is non-NULL, returns the next pointer after filter. |
| 652 | 665 | * If the returned pointer points to NULL, the last registered filter |
| 653 | 666 | * was already reached. |
| 667 | + * @deprecated use avfilter_next() | |
| 654 | 668 | */ |
| 669 | +attribute_deprecated | |
| 655 | 670 | AVFilter **av_filter_next(AVFilter **filter); |
| 671 | +#endif | |
| 656 | 672 | |
| 657 | 673 | #if FF_API_AVFILTER_OPEN |
| 658 | 674 | /** |