summaryrefslogtreecommitdiffstats
path: root/third_party/aom/av1/common/common_data.h
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/aom/av1/common/common_data.h')
-rw-r--r--third_party/aom/av1/common/common_data.h946
1 files changed, 651 insertions, 295 deletions
diff --git a/third_party/aom/av1/common/common_data.h b/third_party/aom/av1/common/common_data.h
index f49c7335a..1a74fe76e 100644
--- a/third_party/aom/av1/common/common_data.h
+++ b/third_party/aom/av1/common/common_data.h
@@ -29,35 +29,93 @@ extern "C" {
// Log 2 conversion lookup tables for block width and height
static const uint8_t b_width_log2_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 0, 0, 0,
-#endif
- 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, IF_EXT_PARTITION(4, 5, 5) 0, 2, 1, 3
+ 0, 0,
+ 0,
+#endif
+ 0, 0,
+ 1, 1,
+ 1, 2,
+ 2, 2,
+ 3, 3,
+ 3, 4,
+ 4, IF_EXT_PARTITION(4, 5, 5) 0,
+ 2, 1,
+ 3, 2,
+ 4, IF_EXT_PARTITION(3, 5)
};
static const uint8_t b_height_log2_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 0, 0, 0,
-#endif
- 0, 1, 0, 1, 2, 1, 2, 3, 2, 3, 4, 3, 4, IF_EXT_PARTITION(5, 4, 5) 2, 0, 3, 1
+ 0, 0,
+ 0,
+#endif
+ 0, 1,
+ 0, 1,
+ 2, 1,
+ 2, 3,
+ 2, 3,
+ 4, 3,
+ 4, IF_EXT_PARTITION(5, 4, 5) 2,
+ 0, 3,
+ 1, 4,
+ 2, IF_EXT_PARTITION(5, 3)
};
// Log 2 conversion lookup tables for modeinfo width and height
static const uint8_t mi_width_log2_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CB4X4
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 0, 0, 0,
-#endif
- 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, IF_EXT_PARTITION(4, 5, 5) 0, 2, 1, 3
+ 0, 0,
+ 0,
+#endif
+ 0, 0,
+ 1, 1,
+ 1, 2,
+ 2, 2,
+ 3, 3,
+ 3, 4,
+ 4, IF_EXT_PARTITION(4, 5, 5) 0,
+ 2, 1,
+ 3, 2,
+ 4, IF_EXT_PARTITION(3, 5)
#else // CONFIG_CB4X4
- 0, 0, 0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, IF_EXT_PARTITION(3, 4, 4) 0, 1, 0, 2
+ 0, 0,
+ 0, 0,
+ 0, 1,
+ 1, 1,
+ 2, 2,
+ 2, 3,
+ 3, IF_EXT_PARTITION(3, 4, 4) 0,
+ 1, 0,
+ 2, 1,
+ 3, IF_EXT_PARTITION(2, 4)
#endif
};
static const uint8_t mi_height_log2_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CB4X4
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 0, 0, 0,
-#endif
- 0, 1, 0, 1, 2, 1, 2, 3, 2, 3, 4, 3, 4, IF_EXT_PARTITION(5, 4, 5) 2, 0, 3, 1
+ 0, 0,
+ 0,
+#endif
+ 0, 1,
+ 0, 1,
+ 2, 1,
+ 2, 3,
+ 2, 3,
+ 4, 3,
+ 4, IF_EXT_PARTITION(5, 4, 5) 2,
+ 0, 3,
+ 1, 4,
+ 2, IF_EXT_PARTITION(5, 3)
#else // CONFIG_CB4X4
- 0, 0, 0, 0, 1, 0, 1, 2, 1, 2, 3, 2, 3, IF_EXT_PARTITION(4, 3, 4) 1, 0, 2, 0
+ 0, 0,
+ 0, 0,
+ 1, 0,
+ 1, 2,
+ 1, 2,
+ 3, 2,
+ 3, IF_EXT_PARTITION(4, 3, 4) 1,
+ 0, 2,
+ 0, 3,
+ 1, IF_EXT_PARTITION(2, 4)
#endif
};
@@ -68,9 +126,10 @@ static const uint8_t mi_size_wide[BLOCK_SIZES_ALL] = {
1, 1, 1,
#endif
1, 1, 2, 2, 2, 4, 4, 4, 8, 8, 8, 16, 16,
- IF_EXT_PARTITION(16, 32, 32) 1, 4, 2, 8
+ IF_EXT_PARTITION(16, 32, 32) 1, 4, 2, 8, 4, 16, IF_EXT_PARTITION(8, 32)
#else // CONFIG_CB4X4
- 1, 1, 1, 1, 1, 2, 2, 2, 4, 4, 4, 8, 8, IF_EXT_PARTITION(8, 16, 16) 1, 2, 1, 4
+ 1, 1, 1, 1, 1, 2, 2, 2, 4, 4, 4, 8, 8, IF_EXT_PARTITION(8, 16, 16) 1, 2, 1, 4,
+ 2, 8, IF_EXT_PARTITION(4, 16)
#endif
};
static const uint8_t mi_size_high[BLOCK_SIZES_ALL] = {
@@ -79,9 +138,10 @@ static const uint8_t mi_size_high[BLOCK_SIZES_ALL] = {
1, 1, 1,
#endif
1, 2, 1, 2, 4, 2, 4, 8, 4, 8, 16, 8, 16,
- IF_EXT_PARTITION(32, 16, 32) 4, 1, 8, 2
+ IF_EXT_PARTITION(32, 16, 32) 4, 1, 8, 2, 16, 4, IF_EXT_PARTITION(32, 8)
#else // CONFIG_CB4X4
- 1, 1, 1, 1, 2, 1, 2, 4, 2, 4, 8, 4, 8, IF_EXT_PARTITION(16, 8, 16) 2, 1, 4, 1
+ 1, 1, 1, 1, 2, 1, 2, 4, 2, 4, 8, 4, 8, IF_EXT_PARTITION(16, 8, 16) 2, 1, 4, 1,
+ 8, 2, IF_EXT_PARTITION(16, 4)
#endif
};
/* clang-format on */
@@ -89,248 +149,171 @@ static const uint8_t mi_size_high[BLOCK_SIZES_ALL] = {
// Width/height lookup tables in units of various block sizes
static const uint8_t block_size_wide[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 2, 2, 4,
+ 2, 2,
+ 4,
#endif
- 4, 4, 8, 8, 8, 16, 16,
- 16, 32, 32, 32, 64, 64, IF_EXT_PARTITION(64, 128, 128) 4,
- 16, 8, 32
+ 4, 4,
+ 8, 8,
+ 8, 16,
+ 16, 16,
+ 32, 32,
+ 32, 64,
+ 64, IF_EXT_PARTITION(64, 128, 128) 4,
+ 16, 8,
+ 32, 16,
+ 64, IF_EXT_PARTITION(32, 128)
};
static const uint8_t block_size_high[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 2, 4, 2,
+ 2, 4,
+ 2,
#endif
- 4, 8, 4, 8, 16, 8, 16,
- 32, 16, 32, 64, 32, 64, IF_EXT_PARTITION(128, 64, 128) 16,
- 4, 32, 8
+ 4, 8,
+ 4, 8,
+ 16, 8,
+ 16, 32,
+ 16, 32,
+ 64, 32,
+ 64, IF_EXT_PARTITION(128, 64, 128) 16,
+ 4, 32,
+ 8, 64,
+ 16, IF_EXT_PARTITION(128, 32)
};
static const uint8_t num_4x4_blocks_wide_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 1, 1, 1,
+ 1, 1,
+ 1,
#endif
- 1, 1, 2, 2, 2, 4, 4, 4, 8, 8, 8, 16, 16, IF_EXT_PARTITION(16, 32, 32) 1,
- 4, 2, 8
+ 1, 1,
+ 2, 2,
+ 2, 4,
+ 4, 4,
+ 8, 8,
+ 8, 16,
+ 16, IF_EXT_PARTITION(16, 32, 32) 1,
+ 4, 2,
+ 8, 4,
+ 16, IF_EXT_PARTITION(8, 32)
};
static const uint8_t num_4x4_blocks_high_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 1, 1, 1,
+ 1, 1,
+ 1,
#endif
- 1, 2, 1, 2, 4, 2, 4, 8, 4, 8, 16, 8, 16, IF_EXT_PARTITION(32, 16, 32) 4,
- 1, 8, 2
+ 1, 2,
+ 1, 2,
+ 4, 2,
+ 4, 8,
+ 4, 8,
+ 16, 8,
+ 16, IF_EXT_PARTITION(32, 16, 32) 4,
+ 1, 8,
+ 2, 16,
+ 4, IF_EXT_PARTITION(32, 8)
};
static const uint8_t num_8x8_blocks_wide_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 1, 1, 1,
+ 1, 1,
+ 1,
#endif
- 1, 1, 1, 1, 1, 2, 2, 2, 4, 4, 4, 8, 8, IF_EXT_PARTITION(8, 16, 16) 1, 2, 1, 4
+ 1, 1,
+ 1, 1,
+ 1, 2,
+ 2, 2,
+ 4, 4,
+ 4, 8,
+ 8, IF_EXT_PARTITION(8, 16, 16) 1,
+ 2, 1,
+ 4, 2,
+ 8, IF_EXT_PARTITION(4, 16)
};
static const uint8_t num_8x8_blocks_high_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 1, 1, 1,
+ 1, 1,
+ 1,
#endif
- 1, 1, 1, 1, 2, 1, 2, 4, 2, 4, 8, 4, 8, IF_EXT_PARTITION(16, 8, 16) 2, 1, 4, 1
+ 1, 1,
+ 1, 1,
+ 2, 1,
+ 2, 4,
+ 2, 4,
+ 8, 4,
+ 8, IF_EXT_PARTITION(16, 8, 16) 2,
+ 1, 4,
+ 1, 8,
+ 2, IF_EXT_PARTITION(16, 4)
};
static const uint8_t num_16x16_blocks_wide_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 1, 1, 1,
+ 1, 1,
+ 1,
#endif
- 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 4, 4, IF_EXT_PARTITION(4, 8, 8) 1, 1, 1, 2
+ 1, 1,
+ 1, 1,
+ 1, 1,
+ 1, 1,
+ 2, 2,
+ 2, 4,
+ 4, IF_EXT_PARTITION(4, 8, 8) 1,
+ 1, 1,
+ 2, 2,
+ 4, IF_EXT_PARTITION(2, 8)
};
static const uint8_t num_16x16_blocks_high_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 1, 1, 1,
+ 1, 1,
+ 1,
#endif
- 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 4, 2, 4, IF_EXT_PARTITION(8, 4, 8) 1, 1, 2, 1
+ 1, 1,
+ 1, 1,
+ 1, 1,
+ 1, 2,
+ 1, 2,
+ 4, 2,
+ 4, IF_EXT_PARTITION(8, 4, 8) 1,
+ 1, 2,
+ 1, 4,
+ 2, IF_EXT_PARTITION(8, 2)
};
// AOMMIN(3, AOMMIN(b_width_log2(bsize), b_height_log2(bsize)))
static const uint8_t size_group_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 0, 0, 0,
-#endif
- 0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 3, 3, IF_EXT_PARTITION(3, 3, 3) 0, 0, 1, 1
+ 0, 0,
+ 0,
+#endif
+ 0, 0,
+ 0, 1,
+ 1, 1,
+ 2, 2,
+ 2, 3,
+ 3, 3,
+ 3, IF_EXT_PARTITION(3, 3, 3) 0,
+ 0, 1,
+ 1, 2,
+ 2, IF_EXT_PARTITION(3, 3)
};
static const uint8_t num_pels_log2_lookup[BLOCK_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- 2, 3, 3,
-#endif
- 4, 5, 5, 6, 7, 7, 8, 9, 9, 10, 11, 11, 12, IF_EXT_PARTITION(13, 13, 14) 6,
- 6, 8, 8
+ 2, 3,
+ 3,
+#endif
+ 4, 5,
+ 5, 6,
+ 7, 7,
+ 8, 9,
+ 9, 10,
+ 11, 11,
+ 12, IF_EXT_PARTITION(13, 13, 14) 6,
+ 6, 8,
+ 8, 10,
+ 10, IF_EXT_PARTITION(12, 12)
};
/* clang-format off */
-static const PARTITION_TYPE
- partition_lookup[MAX_SB_SIZE_LOG2 - 1][BLOCK_SIZES_ALL] = {
- { // 4X4 ->
-#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- // 2X2, 2X4, 4X2,
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif
- // 4X4
- PARTITION_NONE,
- // 4X8, 8X4, 8X8
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 8X16, 16X8, 16X16
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 16X32, 32X16, 32X32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32X64, 64X32, 64X64
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#if CONFIG_EXT_PARTITION
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif // CONFIG_EXT_PARTITION
- // 4x16, 16x4, 8x32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32x8
- PARTITION_INVALID
- }, { // 8X8 ->
-#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- // 2X2, 2X4, 4X2,
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif
- // 4X4
- PARTITION_SPLIT,
- // 4X8, 8X4, 8X8
- PARTITION_VERT, PARTITION_HORZ, PARTITION_NONE,
- // 8X16, 16X8, 16X16
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 16X32, 32X16, 32X32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32X64, 64X32, 64X64
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#if CONFIG_EXT_PARTITION
- // 64x128, 128x64, 128x128
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif // CONFIG_EXT_PARTITION
- // 4x16, 16x4, 8x32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32x8
- PARTITION_INVALID
- }, { // 16X16 ->
-#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- // 2X2, 2X4, 4X2,
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif
- // 4X4
- PARTITION_SPLIT,
- // 4X8, 8X4, 8X8
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 8X16, 16X8, 16X16
- PARTITION_VERT, PARTITION_HORZ, PARTITION_NONE,
- // 16X32, 32X16, 32X32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32X64, 64X32, 64X64
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#if CONFIG_EXT_PARTITION
- // 64x128, 128x64, 128x128
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif // CONFIG_EXT_PARTITION
-#if CONFIG_EXT_PARTITION_TYPES
- // 4x16, 16x4, 8x32
- PARTITION_VERT_4, PARTITION_HORZ_4, PARTITION_INVALID,
- // 32x8
- PARTITION_INVALID
-#else
- // 4x16, 16x4, 8x32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32x8
- PARTITION_INVALID
-#endif
- }, { // 32X32 ->
-#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- // 2X2, 2X4, 4X2,
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif
- // 4X4
- PARTITION_SPLIT,
- // 4X8, 8X4, 8X8
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 8X16, 16X8, 16X16
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 16X32, 32X16, 32X32
- PARTITION_VERT, PARTITION_HORZ, PARTITION_NONE,
- // 32X64, 64X32, 64X64
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#if CONFIG_EXT_PARTITION
- // 64x128, 128x64, 128x128
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif // CONFIG_EXT_PARTITION
-#if CONFIG_EXT_PARTITION_TYPES
- // 4x16, 16x4, 8x32
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_VERT_4,
- // 32x8
- PARTITION_HORZ_4
-#else
- // 4x16, 16x4, 8x32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32x8
- PARTITION_INVALID
-#endif
- }, { // 64X64 ->
-#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- // 2X2, 2X4, 4X2,
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif
- // 4X4
- PARTITION_SPLIT,
- // 4X8, 8X4, 8X8
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 8X16, 16X8, 16X16
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 16X32, 32X16, 32X32
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 32X64, 64X32, 64X64
- PARTITION_VERT, PARTITION_HORZ, PARTITION_NONE,
-#if CONFIG_EXT_PARTITION
- // 64x128, 128x64, 128x128
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif // CONFIG_EXT_PARTITION
-#if CONFIG_EXT_PARTITION_TYPES
- // 4x16, 16x4, 8x32
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 32x8
- PARTITION_SPLIT
-#else
- // 4x16, 16x4, 8x32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32x8
- PARTITION_INVALID
-#endif // CONFIG_EXT_PARTITION_TYPES
-#if CONFIG_EXT_PARTITION
- }, { // 128x128 ->
-#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
- // 2X2, 2X4, 4X2,
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
-#endif
- // 4X4
- PARTITION_SPLIT,
- // 4X8, 8X4, 8X8
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 8X16, 16X8, 16X16
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 16X32, 32X16, 32X32
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 32X64, 64X32, 64X64
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 64x128, 128x64, 128x128
- PARTITION_VERT, PARTITION_HORZ, PARTITION_NONE,
-#if CONFIG_EXT_PARTITION_TYPES
- // 4x16, 16x4, 8x32
- PARTITION_SPLIT, PARTITION_SPLIT, PARTITION_SPLIT,
- // 32x8
- PARTITION_SPLIT
-#else
- // 4x16, 16x4, 8x32
- PARTITION_INVALID, PARTITION_INVALID, PARTITION_INVALID,
- // 32x8
- PARTITION_INVALID
-#endif // CONFIG_EXT_PARTITION_TYPES
-#endif // CONFIG_EXT_PARTITION
- }
-};
-
#if CONFIG_EXT_PARTITION_TYPES
static const BLOCK_SIZE subsize_lookup[EXT_PARTITION_TYPES][BLOCK_SIZES_ALL] =
#else
@@ -358,8 +341,12 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_4X16, BLOCK_16X4, BLOCK_8X32,
- // 32X8,
- BLOCK_32X8,
+ // 32X8, 16X64, 64X16
+ BLOCK_32X8, BLOCK_16X64, BLOCK_64X16,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_32X128, BLOCK_128X32
+#endif // CONFIG_EXT_PARTITION
}, { // PARTITION_HORZ
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
// 2X2, 2X4, 4X2,
@@ -384,8 +371,12 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
}, { // PARTITION_VERT
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
// 2X2, 2X4, 4X2,
@@ -410,8 +401,12 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
}, { // PARTITION_SPLIT
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
// 2X2, 2X4, 4X2,
@@ -433,8 +428,12 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
#if CONFIG_EXT_PARTITION_TYPES
}, { // PARTITION_HORZ_A
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
@@ -457,8 +456,12 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
}, { // PARTITION_HORZ_B
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
// 2X2, 2X4, 4X2,
@@ -480,8 +483,12 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
}, { // PARTITION_VERT_A
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
// 2X2, 2X4, 4X2,
@@ -503,8 +510,12 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
}, { // PARTITION_VERT_B
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
// 2X2, 2X4, 4X2,
@@ -526,8 +537,12 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
}, { // PARTITION_HORZ_4
#if CONFIG_CB4X4
// 2X2, 2X4, 4X2,
@@ -545,15 +560,19 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
// 16X32, 32X16, 32X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_32X8,
// 32X64, 64X32, 64X64
- BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_64X16,
#if CONFIG_EXT_PARTITION
// 64x128, 128x64, 128x128
- BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_128X32,
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
}, { // PARTITION_VERT_4
#if CONFIG_CB4X4
// 2X2, 2X4, 4X2,
@@ -571,15 +590,19 @@ static const BLOCK_SIZE subsize_lookup[PARTITION_TYPES][BLOCK_SIZES_ALL] =
// 16X32, 32X16, 32X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_8X32,
// 32X64, 64X32, 64X64
- BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_16X64,
#if CONFIG_EXT_PARTITION
// 64x128, 128x64, 128x128
- BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_32X128,
#endif // CONFIG_EXT_PARTITION
// 4X16, 16X4, 8X32
BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
- // 32X8,
- BLOCK_INVALID,
+ // 32X8, 16X64, 64X16
+ BLOCK_INVALID, BLOCK_INVALID, BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ BLOCK_INVALID, BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
#endif // CONFIG_EXT_PARTITION_TYPES
}
};
@@ -618,8 +641,12 @@ static const TX_SIZE max_txsize_lookup[BLOCK_SIZES_ALL] = {
#endif // CONFIG_TX64X64
// 4x16, 16x4, 8x32
TX_4X4, TX_4X4, TX_8X8,
- // 32x8
- TX_8X8
+ // 32x8, 16x64 64x16
+ TX_8X8, TX_16X16, TX_16X16,
+#if CONFIG_EXT_PARTITION
+ // 32x128 128x32
+ TX_32X32, TX_32X32
+#endif // CONFIG_EXT_PARTITION
};
#if CONFIG_RECT_TX && (CONFIG_EXT_TX || CONFIG_VAR_TX)
@@ -638,9 +665,9 @@ static const TX_SIZE max_txsize_rect_lookup[BLOCK_SIZES_ALL] = {
TX_8X16, TX_16X8, TX_16X16,
// 16X32, 32X16, 32X32
TX_16X32, TX_32X16, TX_32X32,
- // 32X64, 64X32,
- TX_32X32, TX_32X32,
#if CONFIG_TX64X64
+ // 32X64, 64X32,
+ TX_32X64, TX_64X32,
// 64X64
TX_64X64,
#if CONFIG_EXT_PARTITION
@@ -648,6 +675,8 @@ static const TX_SIZE max_txsize_rect_lookup[BLOCK_SIZES_ALL] = {
TX_64X64, TX_64X64, TX_64X64,
#endif // CONFIG_EXT_PARTITION
#else
+ // 32X64, 64X32,
+ TX_32X32, TX_32X32,
// 64X64
TX_32X32,
#if CONFIG_EXT_PARTITION
@@ -659,13 +688,19 @@ static const TX_SIZE max_txsize_rect_lookup[BLOCK_SIZES_ALL] = {
// 4x16, 16x4, 8x32
TX_4X16, TX_16X4, TX_8X32,
// 32x8
- TX_32X8
+ TX_32X8,
#else
// 4x16, 16x4, 8x32
TX_4X8, TX_8X4, TX_8X16,
// 32x8
- TX_16X8
+ TX_16X8,
#endif
+ // 16x64, 64x16
+ TX_16X32, TX_32X16,
+#if CONFIG_EXT_PARTITION
+ // 32x128 128x32
+ TX_32X32, TX_32X32
+#endif // CONFIG_EXT_PARTITION
};
#if CONFIG_RECT_TX_EXT
@@ -690,8 +725,12 @@ static const TX_SIZE quarter_txsize_lookup[BLOCK_SIZES_ALL] = {
#endif
// 4x16, 16x4, 8x32
TX_4X16, TX_16X4, TX_8X32,
- // 32x8
- TX_32X8
+ // 32x8 16x64 64x16
+ TX_32X8, TX_INVALID, TX_INVALID,
+#if CONFIG_EXT_PARTITION
+ // 32x128 128x32
+ TX_INVALID, TX_INVALID
+#endif // CONFIG_EXT_PARTITION
};
#endif
#else
@@ -738,9 +777,9 @@ static const int32_t intra_tx_size_cat_lookup[BLOCK_SIZES_ALL] = {
TX_16X16 - TX_8X8, TX_16X16 - TX_8X8, TX_16X16 - TX_8X8,
// 16X32, 32X16, 32X32
TX_32X32 - TX_8X8, TX_32X32 - TX_8X8, TX_32X32 - TX_8X8,
- // 32X64, 64X32,
- TX_32X32 - TX_8X8, TX_32X32 - TX_8X8,
#if CONFIG_TX64X64
+ // 32X64, 64X32,
+ TX_64X64 - TX_8X8, TX_64X64 - TX_8X8,
// 64X64
TX_64X64 - TX_8X8,
#if CONFIG_EXT_PARTITION
@@ -748,6 +787,8 @@ static const int32_t intra_tx_size_cat_lookup[BLOCK_SIZES_ALL] = {
TX_64X64 - TX_8X8, TX_64X64 - TX_8X8, TX_64X64 - TX_8X8,
#endif // CONFIG_EXT_PARTITION
#else
+ // 32X64, 64X32,
+ TX_32X32 - TX_8X8, TX_32X32 - TX_8X8,
// 64X64
TX_32X32 - TX_8X8,
#if CONFIG_EXT_PARTITION
@@ -757,10 +798,14 @@ static const int32_t intra_tx_size_cat_lookup[BLOCK_SIZES_ALL] = {
#endif // CONFIG_TX64X64
// TODO(david.barker): Change these if we support rectangular transforms
// for 4:1 shaped partitions
- // 4x16, 16x4, 8x32
- INT32_MIN, INT32_MIN, TX_8X8 - TX_8X8,
- // 32x8
- TX_8X8 - TX_8X8
+ // 4x16, 16x4, 8x32
+ TX_8X8 - TX_8X8, TX_8X8 - TX_8X8, TX_8X8 - TX_8X8,
+ // 32x8, 16x64, 64x16
+ TX_8X8 - TX_8X8, TX_16X16 - TX_8X8, TX_16X16 - TX_8X8,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ TX_32X32 - TX_8X8, TX_32X32 - TX_8X8
+#endif // CONFIG_EXT_PARTITION
};
#else
// Same as "max_txsize_lookup[bsize] - TX_8X8", invalid for bsize < 8X8
@@ -777,9 +822,9 @@ static const int32_t intra_tx_size_cat_lookup[BLOCK_SIZES_ALL] = {
TX_8X8 - TX_8X8, TX_8X8 - TX_8X8, TX_16X16 - TX_8X8,
// 16X32, 32X16, 32X32
TX_16X16 - TX_8X8, TX_16X16 - TX_8X8, TX_32X32 - TX_8X8,
- // 32X64, 64X32,
- TX_32X32 - TX_8X8, TX_32X32 - TX_8X8,
#if CONFIG_TX64X64
+ // 32X64, 64X32,
+ TX_64X64 - TX_8X8, TX_64X64 - TX_8X8,
// 64X64
TX_64X64 - TX_8X8,
#if CONFIG_EXT_PARTITION
@@ -787,6 +832,8 @@ static const int32_t intra_tx_size_cat_lookup[BLOCK_SIZES_ALL] = {
TX_64X64 - TX_8X8, TX_64X64 - TX_8X8, TX_64X64 - TX_8X8,
#endif // CONFIG_EXT_PARTITION
#else
+ // 32X64, 64X32,
+ TX_32X32 - TX_8X8, TX_32X32 - TX_8X8,
// 64X64
TX_32X32 - TX_8X8,
#if CONFIG_EXT_PARTITION
@@ -794,10 +841,14 @@ static const int32_t intra_tx_size_cat_lookup[BLOCK_SIZES_ALL] = {
TX_32X32 - TX_8X8, TX_32X32 - TX_8X8, TX_32X32 - TX_8X8,
#endif // CONFIG_EXT_PARTITION
#endif // CONFIG_TX64X64
- // 4x16, 16x4, 8x32
- INT32_MIN, INT32_MIN, TX_8X8 - TX_8X8,
- // 32x8
- TX_8X8 - TX_8X8
+ // 4x16, 16x4, 8x32
+ TX_8X8 - TX_8X8, TX_8X8 - TX_8X8, TX_8X8 - TX_8X8,
+ // 32x8 16x64, 64x16
+ TX_8X8 - TX_8X8, TX_16X16 - TX_8X8, TX_16X16 - TX_8X8,
+#if CONFIG_EXT_PARTITION
+ // 32x128, 128x32
+ TX_32X32 - TX_8X8, TX_32X32 - TX_8X8
+#endif // CONFIG_EXT_PARTITION
};
#endif // CONFIG_RECT_TX && (CONFIG_EXT_TX || CONFIG_VAR_TX)
@@ -822,6 +873,10 @@ static const TX_SIZE sub_tx_size_map[TX_SIZES_ALL] = {
TX_8X8, // TX_16X8
TX_16X16, // TX_16X32
TX_16X16, // TX_32X16
+#if CONFIG_TX64X64
+ TX_32X32, // TX_32X64
+ TX_32X32, // TX_64X32
+#endif // CONFIG_TX64X64
TX_4X4, // TX_4X16
TX_4X4, // TX_16X4
TX_8X8, // TX_8X32
@@ -845,6 +900,10 @@ static const TX_SIZE txsize_horz_map[TX_SIZES_ALL] = {
TX_16X16, // TX_16X8
TX_16X16, // TX_16X32
TX_32X32, // TX_32X16
+#if CONFIG_TX64X64
+ TX_32X32, // TX_32X64
+ TX_64X64, // TX_64X32
+#endif // CONFIG_TX64X64
TX_4X4, // TX_4X16
TX_16X16, // TX_16X4
TX_8X8, // TX_8X32
@@ -868,6 +927,10 @@ static const TX_SIZE txsize_vert_map[TX_SIZES_ALL] = {
TX_8X8, // TX_16X8
TX_32X32, // TX_16X32
TX_16X16, // TX_32X16
+#if CONFIG_TX64X64
+ TX_64X64, // TX_32X64
+ TX_32X32, // TX_64X32
+#endif // CONFIG_TX64X64
TX_16X16, // TX_4X16
TX_4X4, // TX_16X4
TX_32X32, // TX_8X32
@@ -885,11 +948,15 @@ static const int tx_size_wide[TX_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2
2,
#endif
- 4, 8, 16, 32,
+ 4, 8, 16, 32,
#if CONFIG_TX64X64
64,
#endif // CONFIG_TX64X64
- 4, 8, 8, 16, 16, 32, 4, 16, 8, 32
+ 4, 8, 8, 16, 16, 32,
+#if CONFIG_TX64X64
+ 32, 64,
+#endif // CONFIG_TX64X64
+ 4, 16, 8, 32
};
#if CONFIG_CHROMA_2X2
@@ -903,44 +970,64 @@ static const int tx_size_high[TX_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2
2,
#endif
- 4, 8, 16, 32,
+ 4, 8, 16, 32,
#if CONFIG_TX64X64
64,
#endif // CONFIG_TX64X64
- 8, 4, 16, 8, 32, 16, 16, 4, 32, 8
+ 8, 4, 16, 8, 32, 16,
+#if CONFIG_TX64X64
+ 64, 32,
+#endif // CONFIG_TX64X64
+ 16, 4, 32, 8
};
// Transform block width in unit
static const int tx_size_wide_unit[TX_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2
- 1, 2, 4, 8, 16,
+ 1, 2, 4, 8, 16,
#if CONFIG_TX64X64
32,
#endif // CONFIG_TX64X64
- 2, 4, 4, 8, 8, 16, 2, 8, 4, 16
+ 2, 4, 4, 8, 8, 16,
+#if CONFIG_TX64X64
+ 16, 32,
+#endif // CONFIG_TX64X64
+ 2, 8, 4, 16
#else // CONFIG_CHROMA_2X2
- 1, 2, 4, 8,
+ 1, 2, 4, 8,
#if CONFIG_TX64X64
16,
#endif // CONFIG_TX64X64
- 1, 2, 2, 4, 4, 8, 1, 4, 2, 8
+ 1, 2, 2, 4, 4, 8,
+#if CONFIG_TX64X64
+ 8, 16,
+#endif // CONFIG_TX64X64
+ 1, 4, 2, 8
#endif // CONFIG_CHROMA_2X2
};
// Transform block height in unit
static const int tx_size_high_unit[TX_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2
- 1, 2, 4, 8, 16,
+ 1, 2, 4, 8, 16,
#if CONFIG_TX64X64
32,
#endif // CONFIG_TX64X64
- 4, 2, 8, 4, 16, 8, 8, 2, 16, 4
+ 4, 2, 8, 4, 16, 8,
+#if CONFIG_TX64X64
+ 32, 16,
+#endif // CONFIG_TX64X64
+ 8, 2, 16, 4
#else // CONFIG_CHROMA_2X2
1, 2, 4, 8,
#if CONFIG_TX64X64
16,
#endif // CONFIG_TX64X64
- 2, 1, 4, 2, 8, 4, 4, 1, 8, 2
+ 2, 1, 4, 2, 8, 4,
+#if CONFIG_TX64X64
+ 16, 8,
+#endif // CONFIG_TX64X64
+ 4, 1, 8, 2
#endif // CONFIG_CHROMA_2X2
};
@@ -953,7 +1040,11 @@ static const int tx_size_wide_log2[TX_SIZES_ALL] = {
#if CONFIG_TX64X64
6,
#endif // CONFIG_TX64X64
- 2, 3, 3, 4, 4, 5, 2, 4, 3, 5
+ 2, 3, 3, 4, 4, 5,
+#if CONFIG_TX64X64
+ 5, 6,
+#endif // CONFIG_TX64X64
+ 2, 4, 3, 5
};
// Transform block height in log2
@@ -965,7 +1056,11 @@ static const int tx_size_high_log2[TX_SIZES_ALL] = {
#if CONFIG_TX64X64
6,
#endif // CONFIG_TX64X64
- 3, 2, 4, 3, 5, 4, 4, 2, 5, 3
+ 3, 2, 4, 3, 5, 4,
+#if CONFIG_TX64X64
+ 6, 5,
+#endif // CONFIG_TX64X64
+ 4, 2, 5, 3
};
#define TX_UNIT_WIDE_LOG2 (MI_SIZE_LOG2 - tx_size_wide_log2[0])
@@ -975,11 +1070,15 @@ static const int tx_size_2d[TX_SIZES_ALL] = {
#if CONFIG_CHROMA_2X2
4,
#endif
- 16, 64, 256, 1024,
+ 16, 64, 256, 1024,
#if CONFIG_TX64X64
4096,
#endif // CONFIG_TX64X64
- 32, 32, 128, 128, 512, 512, 64, 64, 256, 256
+ 32, 32, 128, 128, 512, 512,
+#if CONFIG_TX64X64
+ 2048, 2048,
+#endif // CONFIG_TX64X64
+ 64, 64, 256, 256
};
static const BLOCK_SIZE txsize_to_bsize[TX_SIZES_ALL] = {
@@ -999,6 +1098,10 @@ static const BLOCK_SIZE txsize_to_bsize[TX_SIZES_ALL] = {
BLOCK_16X8, // TX_16X8
BLOCK_16X32, // TX_16X32
BLOCK_32X16, // TX_32X16
+#if CONFIG_TX64X64
+ BLOCK_32X64, // TX_32X64
+ BLOCK_64X32, // TX_64X32
+#endif // CONFIG_TX64X64
BLOCK_4X16, // TX_4X16
BLOCK_16X4, // TX_16X4
BLOCK_8X32, // TX_8X32
@@ -1022,6 +1125,10 @@ static const TX_SIZE txsize_sqr_map[TX_SIZES_ALL] = {
TX_8X8, // TX_16X8
TX_16X16, // TX_16X32
TX_16X16, // TX_32X16
+#if CONFIG_TX64X64
+ TX_32X32, // TX_32X64
+ TX_32X32, // TX_64X32
+#endif // CONFIG_TX64X64
TX_4X4, // TX_4X16
TX_4X4, // TX_16X4
TX_8X8, // TX_8X32
@@ -1045,6 +1152,10 @@ static const TX_SIZE txsize_sqr_up_map[TX_SIZES_ALL] = {
TX_16X16, // TX_16X8
TX_32X32, // TX_16X32
TX_32X32, // TX_32X16
+#if CONFIG_TX64X64
+ TX_64X64, // TX_32X64
+ TX_64X64, // TX_64X32
+#endif // CONFIG_TX64X64
TX_16X16, // TX_4X16
TX_16X16, // TX_16X4
TX_32X32, // TX_8X32
@@ -1100,10 +1211,16 @@ static const BLOCK_SIZE ss_size_lookup[BLOCK_SIZES_ALL][2][2] = {
{ { BLOCK_128X64, BLOCK_INVALID }, { BLOCK_64X64, BLOCK_64X32 } },
{ { BLOCK_128X128, BLOCK_128X64 }, { BLOCK_64X128, BLOCK_64X64 } },
#endif // CONFIG_EXT_PARTITION
- { { BLOCK_4X16, BLOCK_4X8 }, { BLOCK_INVALID, BLOCK_INVALID } },
- { { BLOCK_16X4, BLOCK_INVALID }, { BLOCK_8X4, BLOCK_INVALID } },
+ { { BLOCK_4X16, BLOCK_4X8 }, { BLOCK_INVALID, BLOCK_4X8 } },
+ { { BLOCK_16X4, BLOCK_INVALID }, { BLOCK_8X4, BLOCK_8X4 } },
{ { BLOCK_8X32, BLOCK_8X16 }, { BLOCK_INVALID, BLOCK_4X16 } },
{ { BLOCK_32X8, BLOCK_INVALID }, { BLOCK_16X8, BLOCK_16X4 } },
+ { { BLOCK_16X64, BLOCK_16X32 }, { BLOCK_INVALID, BLOCK_8X32 } },
+ { { BLOCK_64X16, BLOCK_INVALID }, { BLOCK_32X16, BLOCK_32X8 } },
+#if CONFIG_EXT_PARTITION
+ { { BLOCK_32X128, BLOCK_32X64 }, { BLOCK_INVALID, BLOCK_16X64 } },
+ { { BLOCK_128X32, BLOCK_INVALID }, { BLOCK_64X32, BLOCK_64X16 } },
+#endif // CONFIG_EXT_PARTITION
};
static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
@@ -1123,6 +1240,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+#if CONFIG_TX64X64
+ { { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+ { { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+#endif // CONFIG_TX64X64
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
@@ -1147,13 +1268,17 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+#if CONFIG_TX64X64
+ { { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+ { { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+#endif // CONFIG_TX64X64
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
},
{
- // BLOCK_2X4
+ // BLOCK_4X2
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
@@ -1165,6 +1290,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+#if CONFIG_TX64X64
+ { { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+ { { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
+#endif // CONFIG_TX64X64
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
{ { TX_2X2, TX_2X2 }, { TX_2X2, TX_2X2 } },
@@ -1175,7 +1304,7 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
},
#elif CONFIG_CHROMA_SUB8X8
{
- // BLOCK_2X2
+ // BLOCK_2x2
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
@@ -1186,6 +1315,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
@@ -1209,13 +1342,17 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
},
{
- // BLOCK_2X4
+ // BLOCK_4X2
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
@@ -1226,6 +1363,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
@@ -1252,6 +1393,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
@@ -1284,6 +1429,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_4X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_4X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_4X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
@@ -1313,6 +1462,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_8X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_8X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_8X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_8X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_8X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_8X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
@@ -1336,6 +1489,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_8X8, TX_8X4 }, { TX_4X8, TX_4X4 } },
{ { TX_8X8, TX_8X4 }, { TX_4X8, TX_4X4 } },
{ { TX_8X8, TX_8X4 }, { TX_4X8, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_8X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X8, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X4 }, { TX_4X8, TX_4X4 } },
{ { TX_8X4, TX_8X4 }, { TX_4X4, TX_4X4 } },
{ { TX_8X8, TX_8X4 }, { TX_4X8, TX_4X4 } },
@@ -1351,7 +1508,7 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_8X8, TX_8X8 }, { TX_4X4, TX_4X4 } },
{ { TX_8X8, TX_8X8 }, { TX_4X4, TX_4X4 } },
#if CONFIG_TX64X64
- { { TX_8X8, TX_8X8 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X16, TX_8X8 }, { TX_4X4, TX_4X4 } },
#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X4, TX_8X4 }, { TX_4X4, TX_4X4 } },
@@ -1359,6 +1516,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_8X16, TX_8X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X16, TX_8X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X16, TX_8X8 }, { TX_4X8, TX_4X8 } },
+#if CONFIG_TX64X64
+ { { TX_8X16, TX_8X8 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X16, TX_8X8 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_8X4, TX_8X4 }, { TX_4X4, TX_4X4 } },
{ { TX_8X16, TX_8X8 }, { TX_4X16, TX_4X8 } },
@@ -1374,7 +1535,7 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_8X8, TX_4X4 }, { TX_8X8, TX_4X4 } },
{ { TX_8X8, TX_4X4 }, { TX_8X8, TX_4X4 } },
#if CONFIG_TX64X64
- { { TX_8X8, TX_4X4 }, { TX_8X8, TX_4X4 } },
+ { { TX_16X8, TX_4X4 }, { TX_8X8, TX_4X4 } },
#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X4 }, { TX_4X8, TX_4X4 } },
{ { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
@@ -1382,6 +1543,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_8X4 }, { TX_8X8, TX_8X4 } }, // used
{ { TX_16X8, TX_8X4 }, { TX_8X8, TX_8X4 } },
{ { TX_16X8, TX_8X4 }, { TX_8X8, TX_8X4 } },
+#if CONFIG_TX64X64
+ { { TX_16X8, TX_4X4 }, { TX_8X8, TX_4X4 } },
+ { { TX_16X8, TX_4X4 }, { TX_8X8, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X4 }, { TX_4X8, TX_4X4 } },
{ { TX_16X4, TX_16X4 }, { TX_8X4, TX_8X4 } },
{ { TX_8X8, TX_8X4 }, { TX_8X8, TX_8X4 } },
@@ -1405,6 +1570,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_8X8, TX_8X8 } },
{ { TX_16X16, TX_16X8 }, { TX_8X16, TX_8X8 } },
{ { TX_16X16, TX_16X8 }, { TX_8X16, TX_8X8 } },
+#if CONFIG_TX64X64
+ { { TX_16X16, TX_8X8 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X16, TX_8X8 }, { TX_8X8, TX_8X8 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_16X4, TX_16X4 }, { TX_8X4, TX_8X4 } },
{ { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
@@ -1420,7 +1589,7 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X16, TX_16X16 }, { TX_8X8, TX_8X8 } },
{ { TX_16X16, TX_16X16 }, { TX_8X8, TX_8X8 } },
#if CONFIG_TX64X64
- { { TX_16X16, TX_16X16 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X32, TX_16X16 }, { TX_8X8, TX_8X8 } },
#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
@@ -1428,6 +1597,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_8X8, TX_8X8 } },
{ { TX_16X32, TX_16X16 }, { TX_8X16, TX_8X16 } }, // used
{ { TX_16X32, TX_16X16 }, { TX_8X16, TX_8X16 } },
+#if CONFIG_TX64X64
+ { { TX_16X32, TX_16X16 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X32, TX_16X16 }, { TX_8X8, TX_8X8 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X16 }, { TX_4X16, TX_4X16 } },
{ { TX_16X4, TX_16X4 }, { TX_8X4, TX_8X4 } },
{ { TX_8X32, TX_8X16 }, { TX_8X32, TX_8X16 } },
@@ -1443,7 +1616,7 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
{ { TX_16X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
#if CONFIG_TX64X64
- { { TX_16X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
+ { { TX_32X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
@@ -1451,6 +1624,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
{ { TX_32X16, TX_16X8 }, { TX_16X16, TX_16X8 } },
{ { TX_32X16, TX_16X8 }, { TX_16X16, TX_16X8 } }, // used
+#if CONFIG_TX64X64
+ { { TX_32X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
+ { { TX_32X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
{ { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
@@ -1474,6 +1651,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
{ { TX_16X32, TX_16X16 }, { TX_16X32, TX_16X16 } },
{ { TX_32X16, TX_32X16 }, { TX_16X16, TX_16X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X32, TX_16X16 }, { TX_16X16, TX_16X16 } },
+ { { TX_32X32, TX_16X16 }, { TX_16X16, TX_16X16 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
{ { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
@@ -1497,6 +1678,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
{ { TX_16X32, TX_16X32 }, { TX_16X16, TX_16X16 } },
{ { TX_32X16, TX_32X16 }, { TX_16X16, TX_16X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X64, TX_32X32 }, { TX_16X16, TX_16X16 } },
+ { { TX_32X32, TX_32X32 }, { TX_16X16, TX_16X16 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
{ { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
@@ -1520,6 +1705,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
{ { TX_16X32, TX_16X16 }, { TX_16X32, TX_16X16 } },
{ { TX_32X16, TX_16X16 }, { TX_32X16, TX_16X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X32, TX_16X16 }, { TX_32X32, TX_16X16 } },
+ { { TX_64X32, TX_16X16 }, { TX_32X32, TX_16X16 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
{ { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
@@ -1543,6 +1732,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
{ { TX_16X32, TX_16X32 }, { TX_16X32, TX_16X32 } },
{ { TX_32X16, TX_32X16 }, { TX_32X16, TX_16X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X64, TX_32X32 }, { TX_16X16, TX_16X16 } },
+ { { TX_64X32, TX_16X16 }, { TX_32X32, TX_16X16 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
{ { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
@@ -1559,7 +1752,7 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X16, TX_16X16 }, { TX_16X16, TX_16X16 } },
{ { TX_32X32, TX_32X32 }, { TX_32X32, TX_32X32 } },
#if CONFIG_TX64X64
- { { TX_64X64, TX_64X64 }, { TX_32X32, TX_32X32 } },
+ { { TX_64X64, TX_32X32 }, { TX_32X32, TX_32X32 } },
#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
@@ -1567,6 +1760,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
{ { TX_16X32, TX_16X32 }, { TX_16X32, TX_16X32 } },
{ { TX_32X16, TX_32X16 }, { TX_32X16, TX_32X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X64, TX_32X32 }, { TX_16X16, TX_16X16 } },
+ { { TX_64X32, TX_16X16 }, { TX_32X32, TX_16X16 } },
+#endif // CONFIG_TX64X64
{ { TX_INVALID, TX_INVALID }, { TX_INVALID, TX_INVALID } },
{ { TX_INVALID, TX_INVALID }, { TX_INVALID, TX_INVALID } },
{ { TX_INVALID, TX_INVALID }, { TX_INVALID, TX_INVALID } },
@@ -1582,7 +1779,7 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X16, TX_16X16 }, { TX_16X16, TX_16X16 } },
{ { TX_32X32, TX_32X32 }, { TX_32X32, TX_32X32 } },
#if CONFIG_TX64X64
- { { TX_64X64, TX_32X32 }, { TX_64X64, TX_32X32 } },
+ { { TX_64X64, TX_32X32 }, { TX_32X32, TX_32X32 } },
#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
@@ -1590,6 +1787,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
{ { TX_16X32, TX_16X32 }, { TX_16X32, TX_16X32 } },
{ { TX_32X16, TX_32X16 }, { TX_32X16, TX_32X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X64, TX_32X32 }, { TX_16X16, TX_16X16 } },
+ { { TX_64X32, TX_16X16 }, { TX_32X32, TX_16X16 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
{ { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
@@ -1605,7 +1806,7 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X16, TX_16X16 }, { TX_16X16, TX_16X16 } },
{ { TX_32X32, TX_32X32 }, { TX_32X32, TX_32X32 } },
#if CONFIG_TX64X64
- { { TX_64X64, TX_64X64 }, { TX_64X64, TX_64X64 } },
+ { { TX_64X64, TX_32X32 }, { TX_32X32, TX_32X32 } },
#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
@@ -1613,6 +1814,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
{ { TX_16X32, TX_16X32 }, { TX_16X32, TX_16X32 } },
{ { TX_32X16, TX_32X16 }, { TX_32X16, TX_32X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X64, TX_32X32 }, { TX_16X16, TX_16X16 } },
+ { { TX_64X32, TX_16X16 }, { TX_32X32, TX_16X16 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
{ { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
{ { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
@@ -1639,6 +1844,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_4X8, TX_4X8 }, { TX_4X4, TX_4X4 } },
{ { TX_4X8, TX_4X8 }, { TX_4X4, TX_4X4 } },
{ { TX_4X8, TX_4X8 }, { TX_4X4, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X8 }, { TX_4X4, TX_4X4 } },
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_4X16, TX_4X8 }, { TX_4X4, TX_4X4 } },
@@ -1664,6 +1873,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_8X4, TX_4X4 }, { TX_8X4, TX_4X4 } },
{ { TX_8X4, TX_4X4 }, { TX_8X4, TX_4X4 } },
{ { TX_8X4, TX_4X4 }, { TX_8X4, TX_4X4 } },
+#if CONFIG_TX64X64
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
{ { TX_16X4, TX_4X4 }, { TX_8X4, TX_4X4 } },
{ { TX_8X4, TX_4X4 }, { TX_8X4, TX_4X4 } },
@@ -1687,6 +1900,10 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_8X8, TX_8X8 }, { TX_4X8, TX_4X8 } },
{ { TX_8X16, TX_8X16 }, { TX_4X8, TX_4X8 } },
{ { TX_8X16, TX_8X16 }, { TX_4X8, TX_4X8 } },
+#if CONFIG_TX64X64
+ { { TX_8X8, TX_8X8 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X8, TX_8X8 }, { TX_4X4, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X16, TX_4X16 }, { TX_4X16, TX_4X16 } },
{ { TX_8X4, TX_8X4 }, { TX_4X4, TX_4X4 } },
{ { TX_8X32, TX_8X16 }, { TX_4X16, TX_4X16 } },
@@ -1710,11 +1927,117 @@ static const TX_SIZE uv_txsize_lookup[BLOCK_SIZES_ALL][TX_SIZES_ALL][2][2] = {
{ { TX_16X8, TX_8X4 }, { TX_16X8, TX_8X4 } },
{ { TX_16X8, TX_8X4 }, { TX_16X8, TX_8X4 } },
{ { TX_16X8, TX_8X4 }, { TX_16X8, TX_8X4 } },
+#if CONFIG_TX64X64
+ { { TX_8X8, TX_4X4 }, { TX_8X8, TX_4X4 } },
+ { { TX_8X8, TX_4X4 }, { TX_8X8, TX_4X4 } },
+#endif // CONFIG_TX64X64
{ { TX_4X8, TX_4X4 }, { TX_4X8, TX_4X4 } },
{ { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
{ { TX_8X8, TX_8X4 }, { TX_8X8, TX_8X4 } },
{ { TX_32X8, TX_16X4 }, { TX_16X8, TX_16X4 } },
- }
+ },
+ {
+// BLOCK_16X64
+#if CONFIG_CHROMA_2X2
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X8, TX_8X8 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X16, TX_16X16 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X16, TX_16X16 }, { TX_8X8, TX_8X8 } },
+#if CONFIG_TX64X64
+ { { TX_16X16, TX_16X16 }, { TX_8X8, TX_8X8 } },
+#endif
+ { { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
+ { { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
+ { { TX_8X16, TX_8X16 }, { TX_8X16, TX_8X16 } },
+ { { TX_16X8, TX_16X8 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X32, TX_16X32 }, { TX_8X16, TX_8X16 } },
+ { { TX_16X16, TX_16X16 }, { TX_8X16, TX_8X16 } },
+#if CONFIG_TX64X64
+ { { TX_16X16, TX_16X16 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X16, TX_16X16 }, { TX_8X8, TX_8X8 } },
+#endif
+ { { TX_4X16, TX_4X16 }, { TX_4X16, TX_4X16 } },
+ { { TX_16X4, TX_16X4 }, { TX_8X4, TX_8X4 } },
+ { { TX_8X32, TX_8X32 }, { TX_8X32, TX_8X32 } },
+ { { TX_16X8, TX_16X8 }, { TX_8X8, TX_8X8 } },
+ },
+ {
+// BLOCK_64X16
+#if CONFIG_CHROMA_2X2
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X8, TX_8X8 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
+ { { TX_16X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
+#if CONFIG_TX64X64
+ { { TX_16X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
+#endif
+ { { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
+ { { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
+ { { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
+ { { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
+ { { TX_16X16, TX_16X8 }, { TX_16X16, TX_16X8 } },
+ { { TX_32X16, TX_16X8 }, { TX_32X16, TX_16X8 } },
+#if CONFIG_TX64X64
+ { { TX_16X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
+ { { TX_16X16, TX_8X8 }, { TX_16X16, TX_8X8 } },
+#endif
+ { { TX_4X16, TX_4X8 }, { TX_4X16, TX_4X8 } },
+ { { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
+ { { TX_8X16, TX_8X8 }, { TX_8X16, TX_8X8 } },
+ { { TX_32X8, TX_32X8 }, { TX_32X8, TX_32X8 } },
+ },
+#if CONFIG_EXT_PARTITION
+ {
+// BLOCK_32X128
+#if CONFIG_CHROMA_2X2
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X8, TX_8X8 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X16, TX_16X16 }, { TX_16X16, TX_16X16 } },
+ { { TX_32X32, TX_32X32 }, { TX_16X16, TX_16X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X32, TX_32X32 }, { TX_16X16, TX_16X16 } },
+#endif
+ { { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
+ { { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
+ { { TX_8X16, TX_8X16 }, { TX_8X16, TX_8X16 } },
+ { { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
+ { { TX_16X32, TX_16X32 }, { TX_16X32, TX_16X32 } },
+ { { TX_32X16, TX_32X16 }, { TX_16X16, TX_16X16 } },
+ { { TX_4X16, TX_4X16 }, { TX_4X16, TX_4X16 } },
+ { { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
+ { { TX_8X32, TX_8X32 }, { TX_8X32, TX_8X32 } },
+ { { TX_32X8, TX_32X8 }, { TX_16X8, TX_16X8 } },
+ },
+ {
+// BLOCK_128X32
+#if CONFIG_CHROMA_2X2
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+#endif
+ { { TX_4X4, TX_4X4 }, { TX_4X4, TX_4X4 } },
+ { { TX_8X8, TX_8X8 }, { TX_8X8, TX_8X8 } },
+ { { TX_16X16, TX_16X16 }, { TX_16X16, TX_16X16 } },
+ { { TX_32X32, TX_16X16 }, { TX_32X32, TX_16X16 } },
+#if CONFIG_TX64X64
+ { { TX_32X32, TX_16X16 }, { TX_32X32, TX_16X16 } },
+#endif
+ { { TX_4X8, TX_4X8 }, { TX_4X8, TX_4X8 } },
+ { { TX_8X4, TX_8X4 }, { TX_8X4, TX_8X4 } },
+ { { TX_8X16, TX_8X16 }, { TX_8X16, TX_8X16 } },
+ { { TX_16X8, TX_16X8 }, { TX_16X8, TX_16X8 } },
+ { { TX_16X32, TX_16X16 }, { TX_16X32, TX_16X16 } },
+ { { TX_32X16, TX_32X16 }, { TX_32X16, TX_32X16 } },
+ { { TX_4X16, TX_4X16 }, { TX_4X16, TX_4X16 } },
+ { { TX_16X4, TX_16X4 }, { TX_16X4, TX_16X4 } },
+ { { TX_8X32, TX_8X16 }, { TX_8X32, TX_8X16 } },
+ { { TX_32X8, TX_32X8 }, { TX_32X8, TX_32X8 } },
+ },
+#endif
};
// Generates 4 bit field in which each bit set to 1 represents
@@ -1748,10 +2071,14 @@ static const struct {
{ 0, 16 }, // 128X64- {0b00000, 0b10000}
{ 0, 0 }, // 128X128-{0b00000, 0b00000}
- { 31, 28 }, // 4X16 - {0b11111, 0b11100}
- { 28, 31 }, // 16X4 - {0b11100, 0b11111}
- { 30, 24 }, // 8X32 - {0b11110, 0b11000}
- { 24, 30 }, // 32X8 - {0b11000, 0b11110}
+ { 31, 28 }, // 4X16 - {0b11111, 0b11100}
+ { 28, 31 }, // 16X4 - {0b11100, 0b11111}
+ { 30, 24 }, // 8X32 - {0b11110, 0b11000}
+ { 24, 30 }, // 32X8 - {0b11000, 0b11110}
+ { 28, 16 }, // 16X64 - {0b11100, 0b10000}
+ { 16, 28 }, // 64X16 - {0b10000, 0b11100}
+ { 24, 0 }, // 32X128- {0b11000, 0b00000}
+ { 0, 24 }, // 128X32- {0b00000, 0b11000}
#else
#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
{ 15, 15 }, // 2X2 - {0b1111, 0b1111}
@@ -1774,12 +2101,24 @@ static const struct {
{ 15, 12 }, // 4X16 - {0b1111, 0b1100}
{ 12, 15 }, // 16X4 - {0b1100, 0b1111}
- { 8, 14 }, // 8X32 - {0b1110, 0b1000}
- { 14, 8 }, // 32X8 - {0b1000, 0b1110}
+ { 8, 14 }, // 8X32 - {0b1110, 0b1000}
+ { 14, 8 }, // 32X8 - {0b1000, 0b1110}
+ { 12, 0 }, // 16X64- {0b1100, 0b0000}
+ { 0, 12 }, // 64X16- {0b0000, 0b1100}
#endif // CONFIG_EXT_PARTITION
};
/* clang-format on */
+#if CONFIG_KF_CTX
+static const int intra_mode_context[INTRA_MODES] = {
+ 0, 1, 2, 3, 4, 4, 4, 4, 3, 0,
+#if CONFIG_SMOOTH_HV
+ 1, 2,
+#endif
+ 0,
+};
+#endif
+
#if CONFIG_SUPERTX
static const TX_SIZE uvsupertx_size_lookup[TX_SIZES][2][2] = {
// ss_x == 0 ss_x == 0 ss_x == 1 ss_x == 1
@@ -1831,8 +2170,25 @@ static const ADAPT_OVERLAP_BLOCK adapt_overlap_block_lookup[BLOCK_SIZES_ALL] = {
ADAPT_OVERLAP_BLOCK_INVALID,
#endif // CONFIG_EXT_PARTITION
ADAPT_OVERLAP_BLOCK_INVALID, ADAPT_OVERLAP_BLOCK_INVALID,
+ ADAPT_OVERLAP_BLOCK_INVALID, ADAPT_OVERLAP_BLOCK_INVALID,
+ ADAPT_OVERLAP_BLOCK_INVALID, ADAPT_OVERLAP_BLOCK_INVALID,
+#if CONFIG_EXT_PARTITION
ADAPT_OVERLAP_BLOCK_INVALID, ADAPT_OVERLAP_BLOCK_INVALID
+#endif // CONFIG_EXT_PARTITION
};
+
+static const BLOCK_SIZE bsize_2_sqr_bsize[BLOCK_SIZES] = {
+#if CONFIG_CHROMA_2X2 || CONFIG_CHROMA_SUB8X8
+ BLOCK_2X2, BLOCK_2X2, BLOCK_2X2,
+#endif
+ BLOCK_4X4, BLOCK_4X4, BLOCK_4X4, BLOCK_8X8, BLOCK_8X8,
+ BLOCK_8X8, BLOCK_16X16, BLOCK_16X16, BLOCK_16X16, BLOCK_32X32,
+ BLOCK_32X32, BLOCK_32X32, BLOCK_64X64,
+#if CONFIG_EXT_PARTITION
+ BLOCK_64X64, BLOCK_64X64,
+#endif
+};
+
#endif // CONFIG_NCOBMC_ADAPT_WEIGHT
#if CONFIG_ADAPT_SCAN