diff options
author | Deb Mukherjee <debargha@google.com> | 2012-09-09 23:10:30 -0700 |
---|---|---|
committer | Deb Mukherjee <debargha@google.com> | 2012-09-10 15:27:56 -0700 |
commit | c5af82b7ed6d89a4a12003b8d1c6b4befcadce92 (patch) | |
tree | 6ec270e54ad3faf1d2e28e256fe248a6c6a6eb7f /vp8/common/blockd.h | |
parent | 00f9eb659034cb5cef0bf063c1b72c72c6333f36 (diff) | |
download | libvpx-c5af82b7ed6d89a4a12003b8d1c6b4befcadce92.tar libvpx-c5af82b7ed6d89a4a12003b8d1c6b4befcadce92.tar.gz libvpx-c5af82b7ed6d89a4a12003b8d1c6b4befcadce92.tar.bz2 libvpx-c5af82b7ed6d89a4a12003b8d1c6b4befcadce92.zip |
Hybrid transform cleanups
Some cleanups that will make it easier to maintain the code
and incorporate upcoming changes on entropy coding for the
hybrid transforms.
Change-Id: I44bdba368f7b8bf203161d7a6d3b1fc2c9e21a8f
Diffstat (limited to 'vp8/common/blockd.h')
-rw-r--r-- | vp8/common/blockd.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/vp8/common/blockd.h b/vp8/common/blockd.h index 9862b28e5..a77ce8709 100644 --- a/vp8/common/blockd.h +++ b/vp8/common/blockd.h @@ -493,7 +493,35 @@ static void txfm_map(BLOCKD *b, B_PREDICTION_MODE bmode) { break; } } + +static TX_TYPE get_tx_type(MACROBLOCKD *xd, BLOCKD *b) { + TX_TYPE tx_type = DCT_DCT; +#if CONFIG_HYBRIDTRANSFORM16X16 + if (xd->mode_info_context->mbmi.txfm_size == TX_16X16) { + if (xd->mode_info_context->mbmi.mode < I8X8_PRED && + xd->q_index < ACTIVE_HT16) + tx_type = b->bmi.as_mode.tx_type; + return tx_type; + } +#endif +#if CONFIG_HYBRIDTRANSFORM8X8 + if (xd->mode_info_context->mbmi.txfm_size == TX_8X8) { + if (xd->mode_info_context->mbmi.mode == I8X8_PRED) + tx_type = b->bmi.as_mode.tx_type; + return tx_type; + } #endif +#if CONFIG_HYBRIDTRANSFORM + if (xd->mode_info_context->mbmi.txfm_size == TX_4X4) { + if (xd->mode_info_context->mbmi.mode == B_PRED && + xd->q_index < ACTIVE_HT) + tx_type = b->bmi.as_mode.tx_type; + return tx_type; + } +#endif +} +#endif + extern void vp8_build_block_doffsets(MACROBLOCKD *xd); extern void vp8_setup_block_dptrs(MACROBLOCKD *xd); |