]> git.sesse.net Git - ffmpeg/blobdiff - tools/probetest.c
avformat: Remove deprecated av_demuxer_open()
[ffmpeg] / tools / probetest.c
index 74045eb4985e286219bde4a24222981299c38cca..6f0e002b743995cdf9c74ee0eabd10f3eba660c5 100644 (file)
@@ -38,9 +38,10 @@ static const char *single_format;
 static void probe(AVProbeData *pd, int type, int p, int size)
 {
     int i = 0;
-    AVInputFormat *fmt = NULL;
+    const AVInputFormat *fmt = NULL;
+    void *fmt_opaque = NULL;
 
-    while ((fmt = av_iformat_next(fmt))) {
+    while ((fmt = av_demuxer_iterate(&fmt_opaque))) {
         if (fmt->flags & AVFMT_NOFILE)
             continue;
         if (fmt->read_probe &&
@@ -65,9 +66,10 @@ static void probe(AVProbeData *pd, int type, int p, int size)
 static void print_times(void)
 {
     int i = 0;
-    AVInputFormat *fmt = NULL;
+    const AVInputFormat *fmt = NULL;
+    void *fmt_opaque = NULL;
 
-    while ((fmt = av_iformat_next(fmt))) {
+    while ((fmt = av_demuxer_iterate(&fmt_opaque))) {
         if (fmt->flags & AVFMT_NOFILE)
             continue;
         if (time_array[i] > 1000000) {
@@ -124,9 +126,6 @@ int main(int argc, char **argv)
         return 1;
     }
 
-    avcodec_register_all();
-    av_register_all();
-
     av_lfg_init(&state, 0xdeadbeef);
 
     pd.buf = NULL;