Use 8x8 DCT transform for I8X8 prediction mode
Apply 2D-DCT transform of dimension 8x8 to encode prediction residuals of I8X8 mode. Brought back block type 3 probability context model for 8x8 tokens, which is used for the coefficients of Y blocks in I8x8 modes. The coefficient costs estimate of I8X8 mode in rate-distortion is also changed appropriately. Performance results: derf: 0.246 yt: 0.114 std-hd: 0.730 hd: 0.670 Change-Id: If1d970eeb4e1827c9f0d2c5b27d33089b347ea27
This commit is contained in:
		@@ -235,6 +235,13 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
 | 
			
		||||
        xd->mode_info_context->mbmi.txfm_size = TX_8X8;
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
#if CONFIG_HTRANS8X8
 | 
			
		||||
  if (xd->mode_info_context->mbmi.mode == I8X8_PRED) {
 | 
			
		||||
    xd->mode_info_context->mbmi.txfm_size = TX_8X8;
 | 
			
		||||
  }
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
  tx_type = xd->mode_info_context->mbmi.txfm_size;
 | 
			
		||||
 | 
			
		||||
  if (xd->mode_info_context->mbmi.mb_skip_coeff) {
 | 
			
		||||
@@ -356,11 +363,28 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
 | 
			
		||||
      int i8x8mode;
 | 
			
		||||
      BLOCKD *b;
 | 
			
		||||
 | 
			
		||||
#if CONFIG_HTRANS8X8
 | 
			
		||||
      int idx = (ib & 0x02) ? (ib + 2) : ib;
 | 
			
		||||
 | 
			
		||||
      short *q  = xd->block[idx].qcoeff;
 | 
			
		||||
      short *dq = xd->block[0].dequant;
 | 
			
		||||
      unsigned char *pre = xd->block[ib].predictor;
 | 
			
		||||
      unsigned char *dst = *(xd->block[ib].base_dst) + xd->block[ib].dst;
 | 
			
		||||
      int stride = xd->dst.y_stride;
 | 
			
		||||
 | 
			
		||||
      tx_type = TX_4X4;
 | 
			
		||||
      xd->mode_info_context->mbmi.txfm_size = TX_4X4;
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
      b = &xd->block[ib];
 | 
			
		||||
      i8x8mode = b->bmi.as_mode.first;
 | 
			
		||||
      RECON_INVOKE(RTCD_VTABLE(recon), intra8x8_predict)
 | 
			
		||||
      (b, i8x8mode, b->predictor);
 | 
			
		||||
 | 
			
		||||
#if CONFIG_HTRANS8X8
 | 
			
		||||
      vp8_dequant_idct_add_8x8_c(q, dq, pre, dst, 16, stride);
 | 
			
		||||
      q += 64;
 | 
			
		||||
#else
 | 
			
		||||
      for (j = 0; j < 4; j++) {
 | 
			
		||||
        b = &xd->block[ib + iblock[j]];
 | 
			
		||||
        if (xd->eobs[ib + iblock[j]] > 1) {
 | 
			
		||||
@@ -374,6 +398,7 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
 | 
			
		||||
          ((int *)b->qcoeff)[0] = 0;
 | 
			
		||||
        }
 | 
			
		||||
      }
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
      b = &xd->block[16 + i];
 | 
			
		||||
      RECON_INVOKE(RTCD_VTABLE(recon), intra_uv4x4_predict)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user