Ignore:
Timestamp:
1 Feb 2013, 04:38:14 (12 years ago)
Author:
mediatek-htm
Message:

1.Fix a bug related to JCT3V-C0129
2.Fix compiler warnings
3.Add document numbers in the MACRO names:

MTK_SAIT_TEMPORAL_FIRST_ORDER_C0141_C0097
MTK_SIMPLIFY_DVTC_C0135
MTK_RELEASE_DV_CONSTRAINT_C0129

From MediaTek
yiwen.chen@…

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-5.1-dev3-Mediatek/source/Lib/TLibCommon/TComResidualGenerator.cpp

    r247 r249  
    220220
    221221#if QC_MULTI_DIS_CAN_A0097
    222 #if MTK_RELEASE_DV_CONSTRAINT
     222#if MTK_RELEASE_DV_CONSTRAINT_C0129
    223223Bool
    224224TComResidualGenerator::getResidualSamples( TComDataCU* pcCU, UInt uiPUIdx, TComYuv* pcYuv, TComMv iDisp
     
    253253  pcCU->getPic()->getPicYuvRec()->getTopLeftSamplePos( pcCU->getAddr(), pcCU->getZorderIdxInCU() + uiPartAddr, iXPos, iYPos );
    254254#if QC_MULTI_DIS_CAN_A0097
    255 #if MTK_RELEASE_DV_CONSTRAINT
     255#if MTK_RELEASE_DV_CONSTRAINT_C0129
    256256  return getResidualSamples( pcCU->getPic(), (UInt)iXPos, (UInt)iYPos, (UInt)iBlkWidth, (UInt)iBlkHeight, pcYuv, iDisp
    257257#if QC_SIMPLIFIEDIVRP_M24938
     
    276276 
    277277#if QC_MULTI_DIS_CAN_A0097
    278 #if MTK_RELEASE_DV_CONSTRAINT
     278#if MTK_RELEASE_DV_CONSTRAINT_C0129
    279279Bool
    280280TComResidualGenerator::getResidualSamples( TComPic* pcPic, UInt uiXPos, UInt uiYPos, UInt uiBlkWidth, UInt uiBlkHeight, TComYuv* pcYuv, TComMv iDisp 
     
    310310#endif
    311311#if QC_MULTI_DIS_CAN_A0097
    312 #if MTK_RELEASE_DV_CONSTRAINT
     312#if MTK_RELEASE_DV_CONSTRAINT_C0129
    313313  xSetPredResidualBlock( pcPic, uiBaseViewId, uiXPos, uiYPos, uiBlkWidth, uiBlkHeight, pcYuv, iDisp
    314314#if QC_SIMPLIFIEDIVRP_M24938
     
    552552
    553553#if QC_MULTI_DIS_CAN_A0097
    554 #if MTK_RELEASE_DV_CONSTRAINT
     554#if MTK_RELEASE_DV_CONSTRAINT_C0129
    555555Void 
    556556TComResidualGenerator::xSetPredResidualBlock( TComPic* pcPic, UInt uiBaseViewId, UInt uiXPos, UInt uiYPos, UInt uiBlkWidth, UInt uiBlkHeight, TComYuv* pcYuv, TComMv iDisp
     
    592592  //===== get disparity =====
    593593#if QC_MULTI_DIS_CAN_A0097
    594 #if MTK_RELEASE_DV_CONSTRAINT
     594#if MTK_RELEASE_DV_CONSTRAINT_C0129
    595595  Int iDisparity_y = iDisp.getVer();
    596596  Int iDisparity   = iDisp.getHor();
     
    610610  Int           iYRefPosX0  = Int( uiXPos )     + ( iDisparity >> 2 );
    611611  Int           iYRefPosX1  = iYRefPosX0        + 1;
    612 #if MTK_RELEASE_DV_CONSTRAINT
     612#if MTK_RELEASE_DV_CONSTRAINT_C0129
    613613  Int           iYMaxPosY   = Int( uiPicHeight ) - 1;
    614614  Int           iYWeight3   = ( iDisparity_y & 3 );
     
    620620  Int           iSrcStrideY = pcBaseRes->getStride   ();
    621621  Int           iDesStrideY = pcYuv    ->getStride   ();
    622 #if MTK_RELEASE_DV_CONSTRAINT
     622#if MTK_RELEASE_DV_CONSTRAINT_C0129
    623623  Pel*          pSrcSamplesY0= pcBaseRes->getLumaAddr ( 0 ) + iYRefPosY0 * iSrcStrideY;
    624624  Pel*          pSrcSamplesY1= pcBaseRes->getLumaAddr ( 0 ) + iYRefPosY1 * iSrcStrideY;
     
    636636    return;
    637637#endif
    638 #if MTK_RELEASE_DV_CONSTRAINT
     638#if MTK_RELEASE_DV_CONSTRAINT_C0129
    639639  for(   Int iY = 0; iY < iYHeight; iY++, pSrcSamplesY0 += iSrcStrideY, pSrcSamplesY1 += iSrcStrideY, pDesSamplesY += iDesStrideY )
    640640#else
     
    646646      Int iXPic0        = Max( 0, Min( iYMaxPosX, iYRefPosX0 + iX ) );
    647647      Int iXPic1        = Max( 0, Min( iYMaxPosX, iYRefPosX1 + iX ) );
    648 #if MTK_RELEASE_DV_CONSTRAINT
     648#if MTK_RELEASE_DV_CONSTRAINT_C0129
    649649      Pel Temp1,Temp2;
    650650      Temp1 =( iYWeight0 * pSrcSamplesY0[iXPic0] + iYWeight1 * pSrcSamplesY0[iXPic1] + 2 ) >> 2;
     
    664664  Int           iCRefPosX0  = Int( uiXPos     >> 1 ) + ( iDisparity >> 3 );
    665665  Int           iCRefPosX1  = iCRefPosX0             + 1;
    666 #if MTK_RELEASE_DV_CONSTRAINT
     666#if MTK_RELEASE_DV_CONSTRAINT_C0129
    667667  Int           iCMaxPosY   = Int( uiPicHeight >> 1 ) - 1;
    668668  Int           iCWeight3   = ( iDisparity_y & 7 );
     
    674674  Int           iSrcStrideC = pcBaseRes->getCStride();
    675675  Int           iDesStrideC = pcYuv    ->getCStride();
    676 #if MTK_RELEASE_DV_CONSTRAINT
    677   Pel*          pSrcSamplesU0= pcBaseRes->getCbAddr ( 0 ) + ( iYRefPosY0 >> 1 ) * iSrcStrideC;
    678   Pel*          pSrcSamplesU1= pcBaseRes->getCbAddr ( 0 ) + ( iYRefPosY1 >> 1 ) * iSrcStrideC;
    679   Pel*          pSrcSamplesV0= pcBaseRes->getCrAddr ( 0 ) + ( iYRefPosY0 >> 1 ) * iSrcStrideC;
    680   Pel*          pSrcSamplesV1= pcBaseRes->getCrAddr ( 0 ) + ( iYRefPosY1 >> 1 ) * iSrcStrideC;
     676#if MTK_RELEASE_DV_CONSTRAINT_C0129
     677  Pel*          pSrcSamplesU0= pcBaseRes->getCbAddr ( 0 ) + ( iCRefPosY0 >> 1 ) * iSrcStrideC;
     678  Pel*          pSrcSamplesU1= pcBaseRes->getCbAddr ( 0 ) + ( iCRefPosY1 >> 1 ) * iSrcStrideC;
     679  Pel*          pSrcSamplesV0= pcBaseRes->getCrAddr ( 0 ) + ( iCRefPosY0 >> 1 ) * iSrcStrideC;
     680  Pel*          pSrcSamplesV1= pcBaseRes->getCrAddr ( 0 ) + ( iCRefPosY1 >> 1 ) * iSrcStrideC;
    681681#else
    682682  Pel*          pSrcSamplesU= pcBaseRes->getCbAddr ( 0 ) + ( uiYPos >> 1 ) * iSrcStrideC;
     
    685685  Pel*          pDesSamplesU= pcYuv    ->getCbAddr ();
    686686  Pel*          pDesSamplesV= pcYuv    ->getCrAddr ();
    687 #if MTK_RELEASE_DV_CONSTRAINT
     687#if MTK_RELEASE_DV_CONSTRAINT_C0129
    688688  for(   Int iY = 0; iY < iCHeight; iY++, pSrcSamplesU0 += iSrcStrideC, pSrcSamplesU1 += iSrcStrideC, pDesSamplesU += iDesStrideC,
    689689                                          pSrcSamplesV0 += iSrcStrideC, pSrcSamplesV1 += iSrcStrideC, pDesSamplesV += iDesStrideC )
     
    697697      Int iXPic0        = Max( 0, Min( iCMaxPosX, iCRefPosX0 + iX ) );
    698698      Int iXPic1        = Max( 0, Min( iCMaxPosX, iCRefPosX1 + iX ) );
    699 #if MTK_RELEASE_DV_CONSTRAINT
     699#if MTK_RELEASE_DV_CONSTRAINT_C0129
    700700      Pel Temp1,Temp2;
    701701      Temp1 =( iCWeight0 * pSrcSamplesU0[iXPic0] + iCWeight1 * pSrcSamplesU0[iXPic1] + 4 ) >> 3;
    702702      Temp2 =( iCWeight0 * pSrcSamplesU1[iXPic0] + iCWeight1 * pSrcSamplesU1[iXPic1] + 4 ) >> 3;
    703       pDesSamplesU[iX]  = ( iYWeight2 * Temp1 + iYWeight3 * Temp2 + 2 ) >> 2;
     703      pDesSamplesU[iX]  = ( iCWeight2 * Temp1 + iCWeight3 * Temp2 + 2 ) >> 2;
    704704      Temp1 =( iCWeight0 * pSrcSamplesV0[iXPic0] + iCWeight1 * pSrcSamplesV0[iXPic1] + 4 ) >> 3;
    705705      Temp2 =( iCWeight0 * pSrcSamplesV1[iXPic0] + iCWeight1 * pSrcSamplesV1[iXPic1] + 4 ) >> 3;
    706       pDesSamplesV[iX]  = ( iYWeight2 * Temp1 + iYWeight3 * Temp2 + 2 ) >> 2;
     706      pDesSamplesV[iX]  = ( iCWeight2 * Temp1 + iCWeight3 * Temp2 + 2 ) >> 2;
    707707#else
    708708      pDesSamplesU[iX]  = ( iCWeight0 * pSrcSamplesU[iXPic0] + iCWeight1 * pSrcSamplesU[iXPic1] + 4 ) >> 3;
Note: See TracChangeset for help on using the changeset viewer.