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

Side by Side Diff: source/libvpx/vp9/common/vp9_mbpitch.c

Issue 11974002: libvpx: Pull from upstream (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/libvpx/
Patch Set: Created 7 years, 11 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 | Annotate | Revision Log
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
11 11
12 #include "vp9/common/vp9_blockd.h" 12 #include "vp9/common/vp9_blockd.h"
13 13
14 typedef enum { 14 typedef enum {
15 PRED = 0, 15 PRED = 0,
16 DEST = 1 16 DEST = 1
17 } BLOCKSET; 17 } BLOCKSET;
18 18
19 static void setup_block 19 static void setup_block(BLOCKD *b,
20 ( 20 int mv_stride,
21 BLOCKD *b, 21 uint8_t **base,
22 int mv_stride, 22 uint8_t **base2,
23 unsigned char **base, 23 int Stride,
24 unsigned char **base2, 24 int offset,
25 int Stride, 25 BLOCKSET bs) {
26 int offset,
27 BLOCKSET bs
28 ) {
29
30 if (bs == DEST) { 26 if (bs == DEST) {
31 b->dst_stride = Stride; 27 b->dst_stride = Stride;
32 b->dst = offset; 28 b->dst = offset;
33 b->base_dst = base; 29 b->base_dst = base;
34 } else { 30 } else {
35 b->pre_stride = Stride; 31 b->pre_stride = Stride;
36 b->pre = offset; 32 b->pre = offset;
37 b->base_pre = base; 33 b->base_pre = base;
38 b->base_second_pre = base2; 34 b->base_second_pre = base2;
39 } 35 }
40
41 } 36 }
42 37
43
44 static void setup_macroblock(MACROBLOCKD *xd, BLOCKSET bs) { 38 static void setup_macroblock(MACROBLOCKD *xd, BLOCKSET bs) {
45 int block; 39 int block;
46 40
47 unsigned char **y, **u, **v; 41 uint8_t **y, **u, **v;
48 unsigned char **y2 = NULL, **u2 = NULL, **v2 = NULL; 42 uint8_t **y2 = NULL, **u2 = NULL, **v2 = NULL;
49 BLOCKD *blockd = xd->block; 43 BLOCKD *blockd = xd->block;
50 int stride; 44 int stride;
51 45
52 if (bs == DEST) { 46 if (bs == DEST) {
53 y = &xd->dst.y_buffer; 47 y = &xd->dst.y_buffer;
54 u = &xd->dst.u_buffer; 48 u = &xd->dst.u_buffer;
55 v = &xd->dst.v_buffer; 49 v = &xd->dst.v_buffer;
56 } else { 50 } else {
57 y = &xd->pre.y_buffer; 51 y = &xd->pre.y_buffer;
58 u = &xd->pre.u_buffer; 52 u = &xd->pre.u_buffer;
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 104
111 blockd[24].diff = &xd->diff[384]; 105 blockd[24].diff = &xd->diff[384];
112 106
113 for (r = 0; r < 25; r++) { 107 for (r = 0; r < 25; r++) {
114 blockd[r].qcoeff = xd->qcoeff + r * 16; 108 blockd[r].qcoeff = xd->qcoeff + r * 16;
115 blockd[r].dqcoeff = xd->dqcoeff + r * 16; 109 blockd[r].dqcoeff = xd->dqcoeff + r * 16;
116 } 110 }
117 } 111 }
118 112
119 void vp9_build_block_doffsets(MACROBLOCKD *xd) { 113 void vp9_build_block_doffsets(MACROBLOCKD *xd) {
120
121 /* handle the destination pitch features */ 114 /* handle the destination pitch features */
122 setup_macroblock(xd, DEST); 115 setup_macroblock(xd, DEST);
123 setup_macroblock(xd, PRED); 116 setup_macroblock(xd, PRED);
124 } 117 }
OLDNEW
« no previous file with comments | « source/libvpx/vp9/common/vp9_loopfilter_filters.c ('k') | source/libvpx/vp9/common/vp9_modecont.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698