summaryrefslogtreecommitdiff
path: root/vp8/common/blockd.h
diff options
context:
space:
mode:
Diffstat (limited to 'vp8/common/blockd.h')
-rw-r--r--vp8/common/blockd.h31
1 files changed, 29 insertions, 2 deletions
diff --git a/vp8/common/blockd.h b/vp8/common/blockd.h
index 96345c2bd..a93232dc7 100644
--- a/vp8/common/blockd.h
+++ b/vp8/common/blockd.h
@@ -479,6 +479,33 @@ 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);
@@ -488,8 +515,8 @@ static void update_blockd_bmi(MACROBLOCKD *xd) {
int i;
int is_4x4;
is_4x4 = (xd->mode_info_context->mbmi.mode == SPLITMV) ||
- (xd->mode_info_context->mbmi.mode == I8X8_PRED) ||
- (xd->mode_info_context->mbmi.mode == B_PRED);
+ (xd->mode_info_context->mbmi.mode == I8X8_PRED) ||
+ (xd->mode_info_context->mbmi.mode == B_PRED);
if (is_4x4) {
for (i = 0; i < 16; i++) {