summaryrefslogtreecommitdiff
path: root/vp9/encoder/vp9_encodeframe.c
diff options
context:
space:
mode:
authorJingning Han <jingning@google.com>2014-07-31 11:50:00 -0700
committerJingning Han <jingning@google.com>2014-07-31 11:51:59 -0700
commit1c3a80b9a1b938786768de968217f86860c95552 (patch)
tree2ea5132c17bfc7d9dc482f0f84418556ea432d08 /vp9/encoder/vp9_encodeframe.c
parentb719d1539df77bd771b822f005371ac5d3de11ac (diff)
downloadlibvpx-1c3a80b9a1b938786768de968217f86860c95552.tar
libvpx-1c3a80b9a1b938786768de968217f86860c95552.tar.gz
libvpx-1c3a80b9a1b938786768de968217f86860c95552.tar.bz2
libvpx-1c3a80b9a1b938786768de968217f86860c95552.zip
Skip calling vp9_block_energy when aq-mode is off
The mb_energy value is used by aq-mode. Turn off computing its value when aq-mode is off. Change-Id: I26c239f124eca45a5ee58b90d19eae00d9a7cda5
Diffstat (limited to 'vp9/encoder/vp9_encodeframe.c')
-rw-r--r--vp9/encoder/vp9_encodeframe.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c
index b1ef3dcac..50980d027 100644
--- a/vp9/encoder/vp9_encodeframe.c
+++ b/vp9/encoder/vp9_encodeframe.c
@@ -1463,7 +1463,7 @@ static void rd_use_partition(VP9_COMP *cpi,
pc_tree->partitioning = partition;
save_context(cpi, mi_row, mi_col, a, l, sa, sl, bsize);
- if (bsize == BLOCK_16X16) {
+ if (bsize == BLOCK_16X16 && cpi->oxcf.aq_mode) {
set_offsets(cpi, tile, mi_row, mi_col, bsize);
x->mb_energy = vp9_block_energy(cpi, x, bsize);
}
@@ -1993,10 +1993,10 @@ static void rd_pick_partition(VP9_COMP *cpi, const TileInfo *const tile,
assert(num_8x8_blocks_wide_lookup[bsize] ==
num_8x8_blocks_high_lookup[bsize]);
- if (bsize == BLOCK_16X16) {
- set_offsets(cpi, tile, mi_row, mi_col, bsize);
+ set_offsets(cpi, tile, mi_row, mi_col, bsize);
+
+ if (bsize == BLOCK_16X16 && cpi->oxcf.aq_mode)
x->mb_energy = vp9_block_energy(cpi, x, bsize);
- }
if (cpi->sf.cb_partition_search && bsize == BLOCK_16X16) {
int cb_partition_search_ctrl = ((pc_tree->index == 0 || pc_tree->index == 3)