|
|
|
@ -54,41 +54,6 @@ static void *format_child_next(void *obj, void *prev) |
|
|
|
|
return NULL; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
#if FF_API_CHILD_CLASS_NEXT |
|
|
|
|
static const AVClass *format_child_class_next(const AVClass *prev) |
|
|
|
|
{ |
|
|
|
|
const AVInputFormat *ifmt = NULL; |
|
|
|
|
const AVOutputFormat *ofmt = NULL; |
|
|
|
|
void *ifmt_iter = NULL, *ofmt_iter = NULL; |
|
|
|
|
|
|
|
|
|
if (!prev) |
|
|
|
|
return &ff_avio_class; |
|
|
|
|
|
|
|
|
|
while ((ifmt = av_demuxer_iterate(&ifmt_iter))) |
|
|
|
|
if (ifmt->priv_class == prev) |
|
|
|
|
break; |
|
|
|
|
|
|
|
|
|
if (!ifmt) { |
|
|
|
|
ifmt_iter = NULL; |
|
|
|
|
while ((ofmt = av_muxer_iterate(&ofmt_iter))) |
|
|
|
|
if (ofmt->priv_class == prev) |
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
|
if (!ofmt) { |
|
|
|
|
ofmt_iter = NULL; |
|
|
|
|
while ((ifmt = av_demuxer_iterate(&ifmt_iter))) |
|
|
|
|
if (ifmt->priv_class) |
|
|
|
|
return ifmt->priv_class; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
while ((ofmt = av_muxer_iterate(&ofmt_iter))) |
|
|
|
|
if (ofmt->priv_class) |
|
|
|
|
return ofmt->priv_class; |
|
|
|
|
|
|
|
|
|
return NULL; |
|
|
|
|
} |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
enum { |
|
|
|
|
CHILD_CLASS_ITER_AVIO = 0, |
|
|
|
|
CHILD_CLASS_ITER_MUX, |
|
|
|
@ -158,9 +123,6 @@ static const AVClass av_format_context_class = { |
|
|
|
|
.option = avformat_options, |
|
|
|
|
.version = LIBAVUTIL_VERSION_INT, |
|
|
|
|
.child_next = format_child_next, |
|
|
|
|
#if FF_API_CHILD_CLASS_NEXT |
|
|
|
|
.child_class_next = format_child_class_next, |
|
|
|
|
#endif |
|
|
|
|
.child_class_iterate = format_child_class_iterate, |
|
|
|
|
.category = AV_CLASS_CATEGORY_MUXER, |
|
|
|
|
.get_category = get_category, |
|
|
|
|