[FFmpeg-cvslog] r30379 - trunk/libswscale/swscale-example.c

stefano subversion
Wed Jan 20 01:22:31 CET 2010


Author: stefano
Date: Wed Jan 20 01:22:31 2010
New Revision: 30379

Log:
Avoid more pointless tests, the input and output formats need to be
supported both as input and as output, as the conversion performed is:
yuva420p -> src -> dst -> yuva420p.

Modified:
   trunk/libswscale/swscale-example.c

Modified: trunk/libswscale/swscale-example.c
==============================================================================
--- trunk/libswscale/swscale-example.c	Tue Jan 19 23:36:46 2010	(r30378)
+++ trunk/libswscale/swscale-example.c	Wed Jan 20 01:22:31 2010	(r30379)
@@ -198,14 +198,14 @@ static void selfTest(uint8_t *ref[4], in
     enum PixelFormat srcFormat, dstFormat;
 
     for (srcFormat = 0; srcFormat < PIX_FMT_NB; srcFormat++) {
-        if (!sws_isSupportedInput(srcFormat))
+        if (!sws_isSupportedInput(srcFormat) || !sws_isSupportedOutput(srcFormat))
             continue;
 
         for (dstFormat = 0; dstFormat < PIX_FMT_NB; dstFormat++) {
             int i, j, k;
             int res = 0;
 
-            if (!sws_isSupportedOutput(dstFormat))
+            if (!sws_isSupportedInput(dstFormat) || !sws_isSupportedOutput(dstFormat))
                 continue;
 
             printf("%s -> %s\n",



More information about the ffmpeg-cvslog mailing list