diff options
author | trav90 <travawine@palemoon.org> | 2018-10-18 06:04:57 -0500 |
---|---|---|
committer | trav90 <travawine@palemoon.org> | 2018-10-18 06:04:57 -0500 |
commit | 7369c7d7a5eed32963d8af37658286617919f91c (patch) | |
tree | 5397ce7ee9bca1641118fdc3187bd9e2b24fdc9c /third_party/aom/av1/encoder/context_tree.c | |
parent | 77887af9c4ad1420bbdb33984af4f74b55ca59db (diff) | |
download | UXP-7369c7d7a5eed32963d8af37658286617919f91c.tar UXP-7369c7d7a5eed32963d8af37658286617919f91c.tar.gz UXP-7369c7d7a5eed32963d8af37658286617919f91c.tar.lz UXP-7369c7d7a5eed32963d8af37658286617919f91c.tar.xz UXP-7369c7d7a5eed32963d8af37658286617919f91c.zip |
Update aom to commit id f5bdeac22930ff4c6b219be49c843db35970b918
Diffstat (limited to 'third_party/aom/av1/encoder/context_tree.c')
-rw-r--r-- | third_party/aom/av1/encoder/context_tree.c | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/third_party/aom/av1/encoder/context_tree.c b/third_party/aom/av1/encoder/context_tree.c index 4c7d6ff00..b1c01b28e 100644 --- a/third_party/aom/av1/encoder/context_tree.c +++ b/third_party/aom/av1/encoder/context_tree.c @@ -65,12 +65,10 @@ static void alloc_mode_context(AV1_COMMON *cm, int num_4x4_blk, } #if CONFIG_PALETTE - if (cm->allow_screen_content_tools) { - for (i = 0; i < 2; ++i) { - CHECK_MEM_ERROR( - cm, ctx->color_index_map[i], - aom_memalign(32, num_pix * sizeof(*ctx->color_index_map[i]))); - } + for (i = 0; i < 2; ++i) { + CHECK_MEM_ERROR( + cm, ctx->color_index_map[i], + aom_memalign(32, num_pix * sizeof(*ctx->color_index_map[i]))); } #endif // CONFIG_PALETTE } @@ -141,7 +139,13 @@ static void alloc_tree_contexts(AV1_COMMON *cm, PC_TREE *tree, &tree->verticalb[1]); alloc_mode_context(cm, num_4x4_blk / 4, PARTITION_VERT_B, &tree->verticalb[2]); -#ifdef CONFIG_SUPERTX + for (int i = 0; i < 4; ++i) { + alloc_mode_context(cm, num_4x4_blk / 4, PARTITION_HORZ_4, + &tree->horizontal4[i]); + alloc_mode_context(cm, num_4x4_blk / 4, PARTITION_HORZ_4, + &tree->vertical4[i]); + } +#if CONFIG_SUPERTX alloc_mode_context(cm, num_4x4_blk, PARTITION_HORZ, &tree->horizontal_supertx); alloc_mode_context(cm, num_4x4_blk, PARTITION_VERT, &tree->vertical_supertx); @@ -159,7 +163,7 @@ static void alloc_tree_contexts(AV1_COMMON *cm, PC_TREE *tree, alloc_mode_context(cm, num_4x4_blk, &tree->none); alloc_mode_context(cm, num_4x4_blk / 2, &tree->horizontal[0]); alloc_mode_context(cm, num_4x4_blk / 2, &tree->vertical[0]); -#ifdef CONFIG_SUPERTX +#if CONFIG_SUPERTX alloc_mode_context(cm, num_4x4_blk, &tree->horizontal_supertx); alloc_mode_context(cm, num_4x4_blk, &tree->vertical_supertx); alloc_mode_context(cm, num_4x4_blk, &tree->split_supertx); @@ -184,13 +188,17 @@ static void free_tree_contexts(PC_TREE *tree) { free_mode_context(&tree->verticala[i]); free_mode_context(&tree->verticalb[i]); } + for (i = 0; i < 4; ++i) { + free_mode_context(&tree->horizontal4[i]); + free_mode_context(&tree->vertical4[i]); + } #endif // CONFIG_EXT_PARTITION_TYPES free_mode_context(&tree->none); free_mode_context(&tree->horizontal[0]); free_mode_context(&tree->horizontal[1]); free_mode_context(&tree->vertical[0]); free_mode_context(&tree->vertical[1]); -#ifdef CONFIG_SUPERTX +#if CONFIG_SUPERTX free_mode_context(&tree->horizontal_supertx); free_mode_context(&tree->vertical_supertx); free_mode_context(&tree->split_supertx); |