Changeset 419 in 3DVCSoftware


Ignore:
Timestamp:
19 May 2013, 18:43:01 (11 years ago)
Author:
mitsubishi-htm
Message:

-macro updates.

Location:
branches/HTM-6.2-dev2-MERL/source/Lib
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-6.2-dev2-MERL/source/Lib/TLibCommon/TComDataCU.cpp

    r418 r419  
    58735873#endif
    58745874
    5875 #if QC_CU_NBDV_D0181 && MERL_VSP_C0152 // TODO: CHECK if the macro is right
     5875#if MERL_General_Fix
     5876#if QC_CU_NBDV_D0181 && MERL_VSP_C0152
    58765877    pDInfo->m_acMvCandNoRef[pDInfo->iN] = defaultDV;
     5878#endif
    58775879#endif
    58785880
  • branches/HTM-6.2-dev2-MERL/source/Lib/TLibCommon/TComPrediction.cpp

    r418 r419  
    788788#endif
    789789
     790#if MERL_General_Fix
    790791#if MERL_VSP_C0152
    791792// Function to perform VSP block compensation
     
    860861}
    861862
    862 
     863#endif
    863864
    864865#if MERL_Bi_VSP_D0166
     
    950951#if QC_ARP_D0177
    951952  if(
    952 #if MERL_VSP_C0152       
    953        vspIdx == 0 &&   // TODO: Maybe logically redundant, but easier to read. Need verification before being removed
     953#if MERL_General_Fix // TODO: Maybe logically redundant, but easier to read. Need verification before being removed
     954#if MERL_VSP_C0152
     955       vspIdx == 0 &&
     956#endif
    954957#endif
    955958       pcCU->getSlice()->getSPS()->isDepth() == false
     
    972975    if (vspIdx != 0)
    973976    { // depth, vsp compensation
     977#if !MERL_General_Fix
     978      // get depth estimator here
     979      TComPic* pRefPicBaseDepth = pcCU->getSlice()->getRefPicBaseDepth();
     980      TComPicYuv* pcBaseViewDepthPicYuv = NULL;
     981      if (vspIdx < 4) // spatial
     982      {
     983        pcBaseViewDepthPicYuv = pRefPicBaseDepth->getPicYuvRec();
     984      }
     985      Int iBlkX = ( pcCU->getAddr() % pRefPicBaseDepth->getFrameWidthInCU() ) * g_uiMaxCUWidth  + g_auiRasterToPelX[ g_auiZscanToRaster[ uiAbsPartIdx ] ];
     986      Int iBlkY = ( pcCU->getAddr() / pRefPicBaseDepth->getFrameWidthInCU() ) * g_uiMaxCUHeight + g_auiRasterToPelY[ g_auiZscanToRaster[ uiAbsPartIdx ] ];
     987      Int* pShiftLUT;
     988      Int iShiftPrec;
     989      pcCU->getSlice()->getBWVSPLUTParam(pShiftLUT, iShiftPrec);
     990      //using disparity to find the depth block of the base view as the depth block estimator of the current block
     991      //using depth block estimator and base view texture to get Backward warping
     992      xPredInterLumaBlkFromDM  ( pcBaseViewDepthPicYuv, pcBaseViewDepthPicYuv, pShiftLUT, iShiftPrec, &cMv, uiPartAddr, iBlkX,    iBlkY,    iWidth,    iHeight,     pcCU->getSlice()->getSPS()->isDepth(), vspIdx, rpcYuvPred );
     993      xPredInterChromaBlkFromDM( pcBaseViewDepthPicYuv, pcBaseViewDepthPicYuv, pShiftLUT, iShiftPrec, &cMv, uiPartAddr, iBlkX>>1, iBlkY>>1, iWidth>>1, iHeight>>1,  pcCU->getSlice()->getSPS()->isDepth(), vspIdx, rpcYuvPred );
     994#else
    974995      xPredInterVSPBlk(pcCU, uiPartAddr, uiAbsPartIdx, iWidth, iHeight, cMv, eRefPicList, rpcYuvPred, bi );
     996#endif
    975997    }
    976998    else
     
    10011023    if ( vspIdx != 0 )
    10021024    { // texture, vsp compensation
     1025#if !MERL_General_Fix
     1026      TComPic*    pRefPicBaseTxt        = pcCU->getSlice()->getRefPicBaseTxt();
     1027      TComPicYuv* pcBaseViewTxtPicYuv   = pRefPicBaseTxt->getPicYuvRec();
     1028      TComPicYuv* pcBaseViewDepthPicYuv = NULL;
     1029      if (vspIdx < 4) // spatial
     1030      {
     1031        TComPic* pRefPicBaseDepth = pcCU->getSlice()->getRefPicBaseDepth();
     1032        pcBaseViewDepthPicYuv     = pRefPicBaseDepth->getPicYuvRec();
     1033      }
     1034      Int iBlkX = ( pcCU->getAddr() % pRefPicBaseTxt->getFrameWidthInCU() ) * g_uiMaxCUWidth  + g_auiRasterToPelX[ g_auiZscanToRaster[ uiAbsPartIdx ] ];
     1035      Int iBlkY = ( pcCU->getAddr() / pRefPicBaseTxt->getFrameWidthInCU() ) * g_uiMaxCUHeight + g_auiRasterToPelY[ g_auiZscanToRaster[ uiAbsPartIdx ] ];
     1036      Int* pShiftLUT;
     1037      Int iShiftPrec;
     1038      pcCU->getSlice()->getBWVSPLUTParam(pShiftLUT, iShiftPrec);
     1039
     1040      //using disparity to find the depth block of the base view as the depth block estimator of the current block
     1041      //using depth block estimator and base view texture to get Backward warping
     1042      xPredInterLumaBlkFromDM  ( pcBaseViewTxtPicYuv, pcBaseViewDepthPicYuv, pShiftLUT, iShiftPrec, &cMv, uiPartAddr, iBlkX,    iBlkY,    iWidth,    iHeight,    pcCU->getSlice()->getSPS()->isDepth(), vspIdx, rpcYuvPred );
     1043      xPredInterChromaBlkFromDM( pcBaseViewTxtPicYuv, pcBaseViewDepthPicYuv, pShiftLUT, iShiftPrec, &cMv, uiPartAddr, iBlkX>>1, iBlkY>>1, iWidth>>1, iHeight>>1, pcCU->getSlice()->getSPS()->isDepth(), vspIdx, rpcYuvPred );
     1044#else
    10031045      xPredInterVSPBlk(pcCU, uiPartAddr, uiAbsPartIdx, iWidth, iHeight, cMv, eRefPicList, rpcYuvPred, bi );
     1046#endif
    10041047    }
    10051048    else//texture not VSP
     
    16861729//
    16871730// Output: dstPic, PU predictor 64x64
    1688 Void TComPrediction::xPredInterLumaBlkFromDM( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv* mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, TComYuv *&dstPic
     1731Void TComPrediction::xPredInterLumaBlkFromDM( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv* mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth
     1732#if !MERL_Bi_VSP_D0166
     1733                                            , Int vspIdx
     1734#endif
     1735                                            , TComYuv *&dstPic
    16891736#if MERL_Bi_VSP_D0166
    16901737                                            , Bool bi
     
    19291976}
    19301977
    1931 Void TComPrediction::xPredInterChromaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv*mv, UInt partAddr, Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, TComYuv *&dstPic
     1978Void TComPrediction::xPredInterChromaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv*mv, UInt partAddr, Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth
     1979#if !MERL_Bi_VSP_D0166
     1980                                               , Int vspIdx
     1981#endif
     1982                                               , TComYuv *&dstPic
    19321983#if MERL_Bi_VSP_D0166
    19331984                                               , Bool bi
  • branches/HTM-6.2-dev2-MERL/source/Lib/TLibCommon/TComPrediction.h

    r416 r419  
    161161    TComYuv *&dstPic, Bool bi);
    162162#else
    163   Void xPredInterLumaBlkFromDM    ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth,
     163  Void xPredInterLumaBlkFromDM    ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, Int vspIdx,
    164164                                  TComYuv *&dstPic );
    165   Void xPredInterChromaBlkFromDM  ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth,
     165  Void xPredInterChromaBlkFromDM  ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, Int vspIdx,
    166166                                  TComYuv *&dstPic );
    167167#endif
  • branches/HTM-6.2-dev2-MERL/source/Lib/TLibCommon/TypeDef.h

    r418 r419  
    187187#if MERL_VSP_C0152
    188188
     189#define MERL_General_Fix                     1 // General fix by MERL
     190
    189191#define MERL_VSP_C0152_BugFix_ForNoDepthCase 1 // MERL bugfix for test condition of no depth
    190192#define MERL_VSP_COMPENSATION_C0152          1 // JCT3V-C0152: 1: add VSP merge candidate to merging candidate list; 0: not to add (nocand).
     
    201203#define MTK_DEPTH_TO_DISP_D0138              1 // JCT3V-D0138: Use max among four corners for DoNBDV and BVSP
    202204
     205#if MERL_General_Fix
    203206#define MTK_LGE_VSP_DEPTH_OFF_D0105_D0139    1 // JCT3V-D0105/JCT3V-D0139: disable VSP for depth map
    204207#define MTK_VSP_USING_NBDV_D0105             1 // JCT3V-D0105: use NBDV instead of DoNBDV for BVSP
    205 
     208#endif
     209
     210#if MERL_General_Fix
    206211#define MERL_VSP_NBDV_RefVId_Fix_D0166       1 // JCT3V-D0166: 1: fix the NBDV with ref view selectioin; 0: always use base view with refViewIdx=0
     212#else
     213#define MERL_VSP_NBDV_RefVId_Fix_D0166       0
     214#endif
     215
    207216#if MERL_VSP_NBDV_RefVId_Fix_D0166
    208217#define MERL_Bi_VSP_D0166                    1 // JCT3V-D0166: 1: add supporting for Bi-VSP, the code under the macro can also handle uni-direction VSP
     218#else
     219#define MERL_Bi_VSP_D0166                    0
    209220#endif
    210221
     
    217228#define MERL_Bi_VSP_D0166                    0 // JCT3V-D0166: 1: add supporting for Bi-VSP, the code under the macro can also handle uni-direction VSP
    218229#define MTK_VSP_USING_NBDV_D0105             0
     230#define MERL_General_Fix                     0
     231#endif
     232
     233#if !MERL_General_Fix
     234#define MTK_LGE_VSP_DEPTH_OFF_D0105_D0139    1 // JCT3V-D0105/JCT3V-D0139: disable VSP for depth map
     235#define MTK_VSP_USING_NBDV_D0105             1 // JCT3V-D0105: use NBDV instead of DoNBDV for BVSP
    219236#endif
    220237
  • branches/HTM-6.2-dev2-MERL/source/Lib/TLibDecoder/TDecCu.cpp

    r412 r419  
    11071107  // reconstruct residual based on mask + DC residuals
    11081108  Pel apDCResiValues[2];
    1109   //Pel apDCRecoValues[2];
     1109#if !MERL_General_Fix
     1110  Pel apDCRecoValues[2];
     1111#endif
    11101112  for( UInt ui = 0; ui < uiNumSegments; ui++ )
    11111113  {
     
    11141116    Pel   pRecoValue  = GetIdx2DepthValue( pPredIdx + pResiIdx );
    11151117   
    1116     //apDCRecoValues[ui]  = pRecoValue;
     1118#if !MERL_General_Fix
     1119    apDCRecoValues[ui]  = pRecoValue;
     1120#endif
    11171121    apDCResiValues[ui]  = pRecoValue - apDCPredValues[ui];
    11181122  }
Note: See TracChangeset for help on using the changeset viewer.