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/common/av1_txfm.h | |
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/common/av1_txfm.h')
-rw-r--r-- | third_party/aom/av1/common/av1_txfm.h | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/third_party/aom/av1/common/av1_txfm.h b/third_party/aom/av1/common/av1_txfm.h index b341cb73d..269ef5705 100644 --- a/third_party/aom/av1/common/av1_txfm.h +++ b/third_party/aom/av1/common/av1_txfm.h @@ -120,11 +120,12 @@ static INLINE int get_max_bit(int x) { } // TODO(angiebird): implement SSE -static INLINE void clamp_block(int16_t *block, int block_size, int stride, - int low, int high) { +static INLINE void clamp_block(int16_t *block, int block_size_row, + int block_size_col, int stride, int low, + int high) { int i, j; - for (i = 0; i < block_size; ++i) { - for (j = 0; j < block_size; ++j) { + for (i = 0; i < block_size_row; ++i) { + for (j = 0; j < block_size_col; ++j) { block[i * stride + j] = clamp(block[i * stride + j], low, high); } } @@ -208,6 +209,16 @@ static INLINE void set_flip_cfg(int tx_type, TXFM_2D_FLIP_CFG *cfg) { } } +#if CONFIG_MRC_TX +static INLINE void get_mrc_mask(const uint8_t *pred, int pred_stride, int *mask, + int mask_stride, int width, int height) { + for (int i = 0; i < height; ++i) { + for (int j = 0; j < width; ++j) + mask[i * mask_stride + j] = pred[i * pred_stride + j] > 100 ? 1 : 0; + } +} +#endif // CONFIG_MRC_TX + #ifdef __cplusplus extern "C" { #endif |