]> git.sesse.net Git - ffmpeg/commitdiff
Merge commit 'c9f8809ee4c576d5833865039bc1c85754448f67'
authorMichael Niedermayer <michaelni@gmx.at>
Mon, 19 May 2014 13:03:42 +0000 (15:03 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Mon, 19 May 2014 13:03:42 +0000 (15:03 +0200)
* commit 'c9f8809ee4c576d5833865039bc1c85754448f67':
  hevc/intra_pred: simplify neighboring sample derivation

Conflicts:
libavcodec/hevcpred_template.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
libavcodec/hevcpred_template.c

index 991e2e7bcf966580028ea4c2ea7a7020de58e0c6,53b9c590b6f9556eade0ef4e0c524d65065ee11b..66499b470c94f3e7e925badf44138a32a89856ae
@@@ -168,26 -172,12 +168,21 @@@ do {                                  
          top[-1]  = left[-1];
      }
      if (cand_up)
-         for (i = 0; i <size; i+=4)
-             AV_WN4P(&top[i], AV_RN4P(&POS(i, -1)));
+         memcpy(top, src - stride, size * sizeof(pixel));
      if (cand_up_right) {
-         a = PIXEL_SPLAT_X4(POS(size + top_right_size - 1, -1));
-         for (i = size + top_right_size; i < (size << 1); i += 4)
-             AV_WN4P(&top[i], a);
-         for (i = size ; i < size+top_right_size; i+=4)
-             AV_WN4P(&top[i], AV_RN4P(&POS(i, -1)));
+         memcpy(top + size, src - stride + size, size * sizeof(pixel));
+         EXTEND(top + size + top_right_size, POS(size + top_right_size - 1, -1),
+                size - top_right_size);
      }
-         for (i = size ; i < size+bottom_left_size; i++)
 +    if (cand_left)
 +        for (i = 0; i < size; i++)
 +            left[i] = POS(-1, i);
 +    if (cand_bottom_left) {
-         a = PIXEL_SPLAT_X4(POS(-1, size + bottom_left_size - 1));
-         for (i = size + bottom_left_size; i < (size << 1); i+=4)
-             AV_WN4P(&left[i], a);
++        for (i = size; i < size + bottom_left_size; i++)
 +            left[i] = POS(-1, i);
++        EXTEND(left + size + bottom_left_size, POS(-1, size + bottom_left_size - 1),
++               size - bottom_left_size);
 +    }
  
      if (s->pps->constrained_intra_pred_flag == 1) {
          if (cand_bottom_left || cand_left || cand_up_left || cand_up || cand_up_right) {