[FFmpeg-soc] [soc]: r3826 - dirac/libavcodec/dirac.c

conrad subversion at mplayerhq.hu
Tue Nov 11 09:38:36 CET 2008


Author: conrad
Date: Tue Nov 11 09:38:35 2008
New Revision: 3826

Log:
Remove redundant checks; they could only be false if the constant tables
contained invalid data


Modified:
   dirac/libavcodec/dirac.c

Modified: dirac/libavcodec/dirac.c
==============================================================================
--- dirac/libavcodec/dirac.c	(original)
+++ dirac/libavcodec/dirac.c	Tue Nov 11 09:38:35 2008
@@ -216,7 +216,7 @@ static int parse_source_parameters(GetBi
             frame_rate.den = svq3_get_ue_golomb(gb);
         }
     }
-    if (source->frame_rate_index > 0 && source->frame_rate_index <= 10) {
+    if (source->frame_rate_index > 0) {
         if (source->frame_rate_index <= 8)
             frame_rate = ff_frame_rate_tab[source->frame_rate_index];
         else
@@ -237,7 +237,7 @@ static int parse_source_parameters(GetBi
             avctx->sample_aspect_ratio.den = svq3_get_ue_golomb(gb);
         }
     }
-    if (source->aspect_ratio_index > 0 && source->aspect_ratio_index <= 6)
+    if (source->aspect_ratio_index > 0)
         avctx->sample_aspect_ratio =
                 dirac_preset_aspect_ratios[source->aspect_ratio_index-1];
 
@@ -263,7 +263,7 @@ static int parse_source_parameters(GetBi
             source->chroma_excursion = svq3_get_ue_golomb(gb);
         }
     }
-    if (source->signal_range_index > 0 && source->signal_range_index <= 4) {
+    if (source->signal_range_index > 0) {
         int idx = source->signal_range_index - 1;
         source->luma_offset      = dirac_preset_luma_offset     [idx];
         source->luma_excursion   = dirac_preset_luma_excursion  [idx];



More information about the FFmpeg-soc mailing list