Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(256)

Side by Side Diff: source/libvpx/vp8/common/extend.c

Issue 1124333011: libvpx: Pull from upstream (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/libvpx.git@master
Patch Set: only update to last nights LKGR Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « source/libvpx/vp8/common/entropymode.c ('k') | source/libvpx/vp8/common/idct_blk.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved. 2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 22 matching lines...) Expand all
33 int linesize; 33 int linesize;
34 34
35 /* copy the left and right most columns out */ 35 /* copy the left and right most columns out */
36 src_ptr1 = s; 36 src_ptr1 = s;
37 src_ptr2 = s + w - 1; 37 src_ptr2 = s + w - 1;
38 dest_ptr1 = d - el; 38 dest_ptr1 = d - el;
39 dest_ptr2 = d + w; 39 dest_ptr2 = d + w;
40 40
41 for (i = 0; i < h; i++) 41 for (i = 0; i < h; i++)
42 { 42 {
43 vpx_memset(dest_ptr1, src_ptr1[0], el); 43 memset(dest_ptr1, src_ptr1[0], el);
44 vpx_memcpy(dest_ptr1 + el, src_ptr1, w); 44 memcpy(dest_ptr1 + el, src_ptr1, w);
45 vpx_memset(dest_ptr2, src_ptr2[0], er); 45 memset(dest_ptr2, src_ptr2[0], er);
46 src_ptr1 += sp; 46 src_ptr1 += sp;
47 src_ptr2 += sp; 47 src_ptr2 += sp;
48 dest_ptr1 += dp; 48 dest_ptr1 += dp;
49 dest_ptr2 += dp; 49 dest_ptr2 += dp;
50 } 50 }
51 51
52 /* Now copy the top and bottom lines into each line of the respective 52 /* Now copy the top and bottom lines into each line of the respective
53 * borders 53 * borders
54 */ 54 */
55 src_ptr1 = d - el; 55 src_ptr1 = d - el;
56 src_ptr2 = d + dp * (h - 1) - el; 56 src_ptr2 = d + dp * (h - 1) - el;
57 dest_ptr1 = d + dp * (-et) - el; 57 dest_ptr1 = d + dp * (-et) - el;
58 dest_ptr2 = d + dp * (h) - el; 58 dest_ptr2 = d + dp * (h) - el;
59 linesize = el + er + w; 59 linesize = el + er + w;
60 60
61 for (i = 0; i < et; i++) 61 for (i = 0; i < et; i++)
62 { 62 {
63 vpx_memcpy(dest_ptr1, src_ptr1, linesize); 63 memcpy(dest_ptr1, src_ptr1, linesize);
64 dest_ptr1 += dp; 64 dest_ptr1 += dp;
65 } 65 }
66 66
67 for (i = 0; i < eb; i++) 67 for (i = 0; i < eb; i++)
68 { 68 {
69 vpx_memcpy(dest_ptr2, src_ptr2, linesize); 69 memcpy(dest_ptr2, src_ptr2, linesize);
70 dest_ptr2 += dp; 70 dest_ptr2 += dp;
71 } 71 }
72 } 72 }
73 73
74 74
75 void vp8_copy_and_extend_frame(YV12_BUFFER_CONFIG *src, 75 void vp8_copy_and_extend_frame(YV12_BUFFER_CONFIG *src,
76 YV12_BUFFER_CONFIG *dst) 76 YV12_BUFFER_CONFIG *dst)
77 { 77 {
78 int et = dst->border; 78 int et = dst->border;
79 int el = dst->border; 79 int el = dst->border;
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 UPtr += ybf->uv_stride; 179 UPtr += ybf->uv_stride;
180 VPtr += ybf->uv_stride; 180 VPtr += ybf->uv_stride;
181 181
182 for (i = 0; i < 4; i++) 182 for (i = 0; i < 4; i++)
183 { 183 {
184 YPtr[i] = YPtr[-1]; 184 YPtr[i] = YPtr[-1];
185 UPtr[i] = UPtr[-1]; 185 UPtr[i] = UPtr[-1];
186 VPtr[i] = VPtr[-1]; 186 VPtr[i] = VPtr[-1];
187 } 187 }
188 } 188 }
OLDNEW
« no previous file with comments | « source/libvpx/vp8/common/entropymode.c ('k') | source/libvpx/vp8/common/idct_blk.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698