]> git.sesse.net Git - vlc/commitdiff
codec/dirac: Fix video format guessing
authorDavid Flynn <davidf@woaf.net>
Sat, 15 Nov 2008 14:13:48 +0000 (14:13 +0000)
committerLaurent Aimar <fenrir@videolan.org>
Sat, 15 Nov 2008 18:39:20 +0000 (19:39 +0100)
Signed-off-by: David Flynn <davidf@rd.bbc.co.uk>
Signed-off-by: Laurent Aimar <fenrir@videolan.org>
modules/codec/dirac.c

index 67af49be643595d360ee262756c3a5fecfd63d6f..6354d330c6ccae43309bb85cc9803e7a5f03e84c 100644 (file)
@@ -351,7 +351,7 @@ static struct
     int i_approx_fps;
     VideoFormat i_vf;
 } dirac_format_guess[] = {
-    /* Important: Keep this list ordered in decending picture height */
+    /* Important: Keep this list ordered in ascending picture height */
     {1, 0, VIDEO_FORMAT_CUSTOM},
     {120, 15, VIDEO_FORMAT_QSIF525},
     {144, 12, VIDEO_FORMAT_QCIF},
@@ -481,7 +481,7 @@ static int OpenEncoder( vlc_object_t *p_this )
      */
     do
     {
-        if( dirac_format_guess[i].i_height < p_enc->fmt_in.video.i_height )
+        if( dirac_format_guess[i].i_height > p_enc->fmt_in.video.i_height )
         {
             guessed_video_fmt = dirac_format_guess[i-1].i_vf;
             break;