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

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

Issue 592203002: libvpx: Pull from upstream (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/libvpx/
Patch Set: Created 6 years, 3 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
« no previous file with comments | « source/libvpx/vp9/common/vp9_blockd.h ('k') | source/libvpx/vp9/common/vp9_common.h » ('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) 2014 The WebM project authors. All Rights Reserved. 2 * Copyright (c) 2014 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 } else { 33 } else {
34 assert(b == 2 || b == 3); 34 assert(b == 2 || b == 3);
35 return cur_mi->bmi[b - 2].as_mode; 35 return cur_mi->bmi[b - 2].as_mode;
36 } 36 }
37 } 37 }
38 38
39 void vp9_foreach_transformed_block_in_plane( 39 void vp9_foreach_transformed_block_in_plane(
40 const MACROBLOCKD *const xd, BLOCK_SIZE bsize, int plane, 40 const MACROBLOCKD *const xd, BLOCK_SIZE bsize, int plane,
41 foreach_transformed_block_visitor visit, void *arg) { 41 foreach_transformed_block_visitor visit, void *arg) {
42 const struct macroblockd_plane *const pd = &xd->plane[plane]; 42 const struct macroblockd_plane *const pd = &xd->plane[plane];
43 const MB_MODE_INFO* mbmi = &xd->mi[0]->mbmi; 43 const MB_MODE_INFO* mbmi = &xd->mi[0].src_mi->mbmi;
44 // block and transform sizes, in number of 4x4 blocks log 2 ("*_b") 44 // block and transform sizes, in number of 4x4 blocks log 2 ("*_b")
45 // 4x4=0, 8x8=2, 16x16=4, 32x32=6, 64x64=8 45 // 4x4=0, 8x8=2, 16x16=4, 32x32=6, 64x64=8
46 // transform size varies per plane, look it up in a common way. 46 // transform size varies per plane, look it up in a common way.
47 const TX_SIZE tx_size = plane ? get_uv_tx_size(mbmi, pd) 47 const TX_SIZE tx_size = plane ? get_uv_tx_size(mbmi, pd)
48 : mbmi->tx_size; 48 : mbmi->tx_size;
49 const BLOCK_SIZE plane_bsize = get_plane_block_size(bsize, pd); 49 const BLOCK_SIZE plane_bsize = get_plane_block_size(bsize, pd);
50 const int num_4x4_w = num_4x4_blocks_wide_lookup[plane_bsize]; 50 const int num_4x4_w = num_4x4_blocks_wide_lookup[plane_bsize];
51 const int num_4x4_h = num_4x4_blocks_high_lookup[plane_bsize]; 51 const int num_4x4_h = num_4x4_blocks_high_lookup[plane_bsize];
52 const int step = 1 << (tx_size << 1); 52 const int step = 1 << (tx_size << 1);
53 int i; 53 int i;
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 140
141 void vp9_setup_block_planes(MACROBLOCKD *xd, int ss_x, int ss_y) { 141 void vp9_setup_block_planes(MACROBLOCKD *xd, int ss_x, int ss_y) {
142 int i; 142 int i;
143 143
144 for (i = 0; i < MAX_MB_PLANE; i++) { 144 for (i = 0; i < MAX_MB_PLANE; i++) {
145 xd->plane[i].plane_type = i ? PLANE_TYPE_UV : PLANE_TYPE_Y; 145 xd->plane[i].plane_type = i ? PLANE_TYPE_UV : PLANE_TYPE_Y;
146 xd->plane[i].subsampling_x = i ? ss_x : 0; 146 xd->plane[i].subsampling_x = i ? ss_x : 0;
147 xd->plane[i].subsampling_y = i ? ss_y : 0; 147 xd->plane[i].subsampling_y = i ? ss_y : 0;
148 } 148 }
149 } 149 }
OLDNEW
« no previous file with comments | « source/libvpx/vp9/common/vp9_blockd.h ('k') | source/libvpx/vp9/common/vp9_common.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698