Commit 0d1be88e authored by Jingning Han's avatar Jingning Han

Scale up the codec to operate in unit of 2x2 transform block

Scale the counting scheme to operate in the unit of 2x2 transform
block size and 4x4 coding block size.

Change-Id: I7c4155c3b29df109278187d5ce0aa78d85a6245e
parent 9eef06df
......@@ -622,31 +622,41 @@ static const int tx_size_high[TX_SIZES_ALL] = {
// Transform block width in unit
static const int tx_size_wide_unit[TX_SIZES_ALL] = {
#if CONFIG_CB4X4
1,
#endif
1, 2, 4, 8, 16,
#if CONFIG_TX64X64
32,
#endif // CONFIG_TX64X64
2, 4, 4, 8, 8, 16,
#else // CONFIG_CB4X4
1, 2, 4, 8,
#if CONFIG_TX64X64
16,
#endif // CONFIG_TX64X64
1, 2, 2, 4, 4, 8,
#endif // CONFIG_CB4X4
};
// Transform block height in unit
static const int tx_size_high_unit[TX_SIZES_ALL] = {
#if CONFIG_CB4X4
1,
#endif
1, 2, 4, 8, 16,
#if CONFIG_TX64X64
32,
#endif // CONFIG_TX64X64
4, 2, 8, 4, 16, 8,
#else // CONFIG_CB4X4
1, 2, 4, 8,
#if CONFIG_TX64X64
16,
#endif // CONFIG_TX64X64
2, 1, 4, 2, 8, 4,
#endif // CONFIG_CB4X4
};
// Transform block width in log2
static const int tx_size_wide_log2[TX_SIZES_ALL] = {
#if CONFIG_CB4X4
2,
1,
#endif
2, 3, 4, 5,
#if CONFIG_TX64X64
......@@ -658,7 +668,7 @@ static const int tx_size_wide_log2[TX_SIZES_ALL] = {
// Transform block height in log2
static const int tx_size_high_log2[TX_SIZES_ALL] = {
#if CONFIG_CB4X4
2,
1,
#endif
2, 3, 4, 5,
#if CONFIG_TX64X64
......@@ -680,7 +690,7 @@ static const int tx_size_2d[TX_SIZES_ALL] = {
static const BLOCK_SIZE txsize_to_bsize[TX_SIZES_ALL] = {
#if CONFIG_CB4X4
BLOCK_4X4, // TX_2X2
BLOCK_2X2, // TX_2X2
#endif
BLOCK_4X4, // TX_4X4
BLOCK_8X8, // TX_8X8
......
......@@ -35,7 +35,11 @@ extern "C" {
#define MIN_SB_SIZE_LOG2 6
// Pixels per Mode Info (MI) unit
#if CONFIG_CB4X4
#define MI_SIZE_LOG2 2
#else
#define MI_SIZE_LOG2 3
#endif
#define MI_SIZE (1 << MI_SIZE_LOG2)
// MI-units per max superblock (MI Block - MIB)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment