]> granicus.if.org Git - libvpx/commitdiff
Rd check on segment level reference mode.
authorPaul Wilkins <paulwilkins@google.com>
Mon, 10 Jun 2013 17:19:25 +0000 (18:19 +0100)
committerRonald S. Bultje <rbultje@google.com>
Mon, 10 Jun 2013 18:03:15 +0000 (11:03 -0700)
Do not allow the rd code to check compound modes if
a segment level reference frame is selected.

Change-Id: I95f0c57789e0eaceed7caf227e94b4ba3130a06c

vp9/encoder/vp9_rdopt.c

index 3d710dcf66e993b3ca4c5bc27af8f4a3da71cc33..c1a27638ee1a19fd46d1c87e8ab21c600da30388 100644 (file)
@@ -2580,6 +2580,12 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x,
         cpi->rd_threshes[bsize][mode_index] == INT_MAX)
       continue;
 
+    // Do not allow compound prediction if the segment level reference
+    // frame feature is in use as in this case there can only be one reference.
+    if ((vp9_mode_order[mode_index].second_ref_frame > INTRA_FRAME) &&
+         vp9_segfeature_active(xd, segment_id, SEG_LVL_REF_FRAME))
+      continue;
+
     x->skip = 0;
     this_mode = vp9_mode_order[mode_index].mode;
     ref_frame = vp9_mode_order[mode_index].ref_frame;