static int show_formats_devices(void *optctx, const char *opt, const char *arg, int device_only, int muxdemuxers)
{
- AVInputFormat *ifmt = NULL;
- AVOutputFormat *ofmt = NULL;
+ void *ifmt_opaque = NULL;
+ const AVInputFormat *ifmt = NULL;
+ void *ofmt_opaque = NULL;
+ const AVOutputFormat *ofmt = NULL;
const char *last_name;
int is_dev;
const char *long_name = NULL;
if (muxdemuxers !=SHOW_DEMUXERS) {
- while ((ofmt = av_oformat_next(ofmt))) {
+ ofmt_opaque = NULL;
+ while ((ofmt = av_muxer_iterate(&ofmt_opaque))) {
is_dev = is_device(ofmt->priv_class);
if (!is_dev && device_only)
continue;
}
}
if (muxdemuxers != SHOW_MUXERS) {
- while ((ifmt = av_iformat_next(ifmt))) {
+ ifmt_opaque = NULL;
+ while ((ifmt = av_demuxer_iterate(&ifmt_opaque))) {
is_dev = is_device(ifmt->priv_class);
if (!is_dev && device_only)
continue;
void *opaque = NULL;
printf("Bitstream filters:\n");
- while ((bsf = av_bsf_next(&opaque)))
+ while ((bsf = av_bsf_iterate(&opaque)))
printf("%s\n", bsf->name);
printf("\n");
return 0;
#if CONFIG_AVFILTER
const AVFilter *filter = NULL;
char descr[64], *descr_cur;
+ void *opaque = NULL;
int i, j;
const AVFilterPad *pad;
" V = Video input/output\n"
" N = Dynamic number and/or type of input/output\n"
" | = Source or sink filter\n");
- while ((filter = avfilter_next(filter))) {
+ while ((filter = av_filter_iterate(&opaque))) {
descr_cur = descr;
for (i = 0; i < 2; i++) {
if (i) {
}
#endif
+static void show_help_bsf(const char *name)
+{
+ const AVBitStreamFilter *bsf = av_bsf_get_by_name(name);
+
+ if (!bsf) {
+ av_log(NULL, AV_LOG_ERROR, "Unknown bit stream filter '%s'.\n", name);
+ return;
+ }
+
+ printf("Bit stream filter %s\n", bsf->name);
+ PRINT_CODEC_SUPPORTED(bsf, codec_ids, enum AVCodecID, "codecs",
+ AV_CODEC_ID_NONE, GET_CODEC_NAME);
+ if (bsf->priv_class)
+ show_help_children(bsf->priv_class, AV_OPT_FLAG_BSF_PARAM);
+}
+
int show_help(void *optctx, const char *opt, const char *arg)
{
char *topic, *par;
} else if (!strcmp(topic, "filter")) {
show_help_filter(par);
#endif
+ } else if (!strcmp(topic, "bsf")) {
+ show_help_bsf(par);
} else {
show_help_default(topic, par);
}