Revision 0c55c6d3

View differences:

cmdutils.c
508 508
    );
509 509
}
510 510

  
511
void list_fmts(void (*get_fmt_string)(char *buf, int buf_size, int fmt), int nb_fmts)
512
{
513
    int i;
514
    char fmt_str[128];
515
    for (i=-1; i < nb_fmts; i++) {
516
        get_fmt_string (fmt_str, sizeof(fmt_str), i);
517
        fprintf(stdout, "%s\n", fmt_str);
518
    }
519
}
520

  
521 511
void show_formats(void)
522 512
{
523 513
    AVInputFormat *ifmt=NULL;
cmdutils.h
161 161
 */
162 162
void print_error(const char *filename, int err);
163 163

  
164
void list_fmts(void (*get_fmt_string)(char *buf, int buf_size, int fmt), int nb_fmts);
165

  
166 164
/**
167 165
 * Print the program banner to stderr. The banner contents depend on the
168 166
 * current version of the repository and of the libav* libraries used by
ffmpeg.c
2850 2850
            ffmpeg_exit(1);
2851 2851
        }
2852 2852
    } else {
2853
        list_fmts(av_get_sample_fmt_string, AV_SAMPLE_FMT_NB);
2853
        int i;
2854
        char fmt_str[128];
2855
        for (i = -1; i < AV_SAMPLE_FMT_NB; i++)
2856
            printf("%s\n", av_get_sample_fmt_string(fmt_str, sizeof(fmt_str), i));
2854 2857
        ffmpeg_exit(0);
2855 2858
    }
2856 2859
}

Also available in: Unified diff