vc1dec: Factorize picture pointer selection in vc1_mc_4mv_chroma()
authorMichael Niedermayer <michaelni@gmx.at>
Wed, 24 Apr 2013 12:59:49 +0000 (14:59 +0200)
committerMartin Storsjö <martin@martin.st>
Wed, 15 May 2013 08:40:17 +0000 (11:40 +0300)
Signed-off-by: Martin Storsjö <martin@martin.st>
libavcodec/vc1dec.c

index b13e91f..f56f074 100644 (file)
@@ -829,14 +829,9 @@ static void vc1_mc_4mv_chroma(VC1Context *v, int dir)
     }
 
     if (!dir) {
     }
 
     if (!dir) {
-        if (v->field_mode) {
-            if ((v->cur_field_type != chroma_ref_type) && v->cur_field_type) {
-                srcU = s->current_picture.f.data[1];
-                srcV = s->current_picture.f.data[2];
-            } else {
-                srcU = s->last_picture.f.data[1];
-                srcV = s->last_picture.f.data[2];
-            }
+        if (v->field_mode && (v->cur_field_type != chroma_ref_type) && v->cur_field_type) {
+            srcU = s->current_picture.f.data[1];
+            srcV = s->current_picture.f.data[2];
         } else {
             srcU = s->last_picture.f.data[1];
             srcV = s->last_picture.f.data[2];
         } else {
             srcU = s->last_picture.f.data[1];
             srcV = s->last_picture.f.data[2];