X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavutil%2Flog.h;h=8edd6bbf2b8bdd21dd711565fc1b4ac51e160d44;hb=e3d993fab0ad4255dffd10a794fc5e1bd37047b7;hp=9c14188a9c924a5aa9ee054bcfd09dd1d419729a;hpb=3182114f8815cb3324dd300d8254ecdb07dbe097;p=ffmpeg diff --git a/libavutil/log.h b/libavutil/log.h index 9c14188a9c9..8edd6bbf2b8 100644 --- a/libavutil/log.h +++ b/libavutil/log.h @@ -112,6 +112,7 @@ typedef struct AVClass { */ void* (*child_next)(void *obj, void *prev); +#if FF_API_CHILD_CLASS_NEXT /** * Return an AVClass corresponding to the next potential * AVOptions-enabled child. @@ -120,7 +121,9 @@ typedef struct AVClass { * child_next iterates over _already existing_ objects, while * child_class_next iterates over _all possible_ children. */ + attribute_deprecated const struct AVClass* (*child_class_next)(const struct AVClass *prev); +#endif /** * Category used for visualization (like color) @@ -140,6 +143,21 @@ typedef struct AVClass { * available since version (52.12) */ int (*query_ranges)(struct AVOptionRanges **, void *obj, const char *key, int flags); + + /** + * Iterate over the AVClasses corresponding to potential AVOptions-enabled + * children. + * + * @param iter pointer to opaque iteration state. The caller must initialize + * *iter to NULL before the first call. + * @return AVClass for the next AVOptions-enabled child or NULL if there are + * no more such children. + * + * @note The difference between child_next and this is that child_next + * iterates over _already existing_ objects, while child_class_iterate + * iterates over _all possible_ children. + */ + const struct AVClass* (*child_class_iterate)(void **iter); } AVClass; /**