diff options
author | Deb Mukherjee <debargha@google.com> | 2013-11-05 17:25:38 -0800 |
---|---|---|
committer | Deb Mukherjee <debargha@google.com> | 2013-11-12 10:13:27 -0800 |
commit | 5ade423774690e2bf877559dc1a1f9547db5dac1 (patch) | |
tree | 877a9fa9e499faaa5acccec5c2eb1c67cc6ea1e5 /vp9/common | |
parent | e5ed605f01f8b75a8e7db1561bdbb373f8040de3 (diff) | |
download | libvpx-5ade423774690e2bf877559dc1a1f9547db5dac1.tar libvpx-5ade423774690e2bf877559dc1a1f9547db5dac1.tar.gz libvpx-5ade423774690e2bf877559dc1a1f9547db5dac1.tar.bz2 libvpx-5ade423774690e2bf877559dc1a1f9547db5dac1.zip |
Removes conditional statements from band getting
Implements scan order to band map with arrays in both the encoder
and decoder to remove conditional statements.
Encoding seems to be about 1% faster at speed 0, tested on football.
Decoding seems to be about 0.5-1% faster on a set of 25 videos.
Change-Id: Idb233ca0b9e0efd790e30880642e8717e1c5c8dd
Diffstat (limited to 'vp9/common')
-rw-r--r-- | vp9/common/vp9_entropy.h | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/vp9/common/vp9_entropy.h b/vp9/common/vp9_entropy.h index c58e852fe..ccb9c4c55 100644 --- a/vp9/common/vp9_entropy.h +++ b/vp9/common/vp9_entropy.h @@ -127,12 +127,6 @@ static INLINE void reset_skip_context(MACROBLOCKD *xd, BLOCK_SIZE bsize) { extern const uint8_t vp9_coefband_trans_8x8plus[MAXBAND_INDEX + 1]; extern const uint8_t vp9_coefband_trans_4x4[MAXBAND_INDEX + 1]; - -static int get_coef_band(const uint8_t * band_translate, int coef_index) { - return (coef_index > MAXBAND_INDEX) - ? (COEF_BANDS-1) : band_translate[coef_index]; -} - // 128 lists of probabilities are stored for the following ONE node probs: // 1, 3, 5, 7, ..., 253, 255 // In between probabilities are interpolated linearly @@ -181,11 +175,6 @@ static int get_entropy_context(TX_SIZE tx_size, const ENTROPY_CONTEXT *a, return combine_entropy_contexts(above_ec, left_ec); } -static const uint8_t *get_band_translate(TX_SIZE tx_size) { - return tx_size == TX_4X4 ? vp9_coefband_trans_4x4 - : vp9_coefband_trans_8x8plus; -} - static void get_scan(const MACROBLOCKD *xd, TX_SIZE tx_size, PLANE_TYPE type, int block_idx, const int16_t **scan, const int16_t **scan_nb) { |