tools/fourcc2pixfmt: Avoid using non public AV_PIX_FMT_NB
authorMichael Niedermayer <michaelni@gmx.at>
Mon, 9 Jun 2014 22:44:11 +0000 (00:44 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Tue, 10 Jun 2014 02:00:06 +0000 (04:00 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tools/fourcc2pixfmt.c

index 1a653ed..1cfdf6a 100644 (file)
@@ -100,7 +100,7 @@ int main(int argc, char **argv)
     }
 
     if (list_pix_fmt_fourccs) {
-        for (i = 0; i < AV_PIX_FMT_NB; i++) {
+        for (i = 0; av_pix_fmt_desc_get(i); i++) {
             const AVPixFmtDescriptor *pix_desc = av_pix_fmt_desc_get(i);
             if (!pix_desc->name || pix_desc->flags & AV_PIX_FMT_FLAG_HWACCEL)
                 continue;