Changeset 724 in 3DVCSoftware for trunk/source/Lib/TLibDecoder/TDecCu.cpp


Ignore:
Timestamp:
30 Nov 2013, 12:29:49 (11 years ago)
Author:
tech
Message:

Merged HTM-8.2-dev0@723.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/Lib/TLibDecoder/TDecCu.cpp

    r655 r724  
    135135Void TDecCu::decompressCU( TComDataCU* pcCU )
    136136{
     137#if !QC_DEPTH_IV_MRG_F0125
    137138  xDecompressCU( pcCU, 0,  0 );
     139#endif
    138140}
    139141
     
    313315      m_ppcCU[uiDepth]->setHeight ( 0, pcCU->getSlice()->getSPS()->getMaxCUHeight()/(1<<uiDepth)  );
    314316      m_ppcCU[uiDepth]->setPartSizeSubParts( SIZE_2Nx2N, 0, uiDepth );     
     317#if QC_DEPTH_IV_MRG_F0125
     318      if( pcCU->getSlice()->getIsDepth())
     319      {
     320        DvInfo.bDV = m_ppcCU[uiDepth]->getDispNeighBlocks(0, 0, &DvInfo);
     321      }
     322      else
     323      {
     324#endif
    315325#if H_3D_NBDV_REF
    316326      if(pcCU->getSlice()->getVPS()->getDepthRefinementFlag( pcCU->getSlice()->getLayerIdInVps() ))  //Notes from QC: please check the condition for DoNBDV. Remove this comment once it is done.
     
    323333        DvInfo.bDV = m_ppcCU[uiDepth]->getDisMvpCandNBDV(&DvInfo);
    324334      }
    325 
     335#if QC_DEPTH_IV_MRG_F0125
     336      }
     337#endif
    326338#if ENC_DEC_TRACE && H_MV_ENC_DEC_TRAC   
    327339      if ( g_decTraceDispDer )
     
    378390    UInt uiMergeIndex = pcCU->getMergeIndex(uiAbsPartIdx);
    379391
     392#if LGE_SHARP_VSP_INHERIT_F0104
     393#if H_3D_IC
     394    m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
     395#endif
     396#if H_3D_ARP
     397    m_pcEntropyDecoder->decodeARPW( pcCU , uiAbsPartIdx , uiDepth );
     398#endif
     399#endif
     400
    380401#if H_3D_VSP
    381402    Int vspFlag[MRG_MAX_NUM_CANDS_MEM];
    382403    memset(vspFlag, 0, sizeof(Int)*MRG_MAX_NUM_CANDS_MEM);
    383404    InheritedVSPDisInfo inheritedVSPDisInfo[MRG_MAX_NUM_CANDS_MEM];
     405#if MTK_SPIVMP_F0110
     406    Bool bSPIVMPFlag[MRG_MAX_NUM_CANDS_MEM];
     407    memset(bSPIVMPFlag, false, sizeof(Bool)*MRG_MAX_NUM_CANDS_MEM);
     408    TComMvField*  pcMvFieldSP;
     409    UChar* puhInterDirSP;
     410    pcMvFieldSP = new TComMvField[pcCU->getPic()->getPicSym()->getNumPartition()*2];
     411    puhInterDirSP = new UChar[pcCU->getPic()->getPicSym()->getNumPartition()];
     412#endif
     413#if ETRIKHU_MERGE_REUSE_F0093
     414    m_ppcCU[uiDepth]->initAvailableFlags();
     415    m_ppcCU[uiDepth]->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
     416    m_ppcCU[uiDepth]->xGetInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, vspFlag, inheritedVSPDisInfo
     417#if MTK_SPIVMP_F0110
     418      , bSPIVMPFlag, pcMvFieldSP, puhInterDirSP
     419#endif
     420      , numValidMergeCand, uiMergeIndex );
     421#else
    384422    m_ppcCU[uiDepth]->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, vspFlag, inheritedVSPDisInfo, numValidMergeCand, uiMergeIndex );
     423#endif
    385424    pcCU->setVSPFlagSubParts( vspFlag[uiMergeIndex], uiAbsPartIdx, 0, uiDepth );
    386425#else
     426#if ETRIKHU_MERGE_REUSE_F0093
     427    m_ppcCU[uiDepth]->initAvailableFlags();
    387428    m_ppcCU[uiDepth]->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
     429    m_ppcCU[uiDepth]->xGetInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
     430#else
     431    m_ppcCU[uiDepth]->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
     432#endif
    388433#endif
    389434#if H_3D_VSP
     
    423468      }
    424469    }
     470#if MTK_SPIVMP_F0110
     471    pcCU->setSPIVMPFlagSubParts(bSPIVMPFlag[uiMergeIndex], uiAbsPartIdx, 0, uiDepth );
     472    if (bSPIVMPFlag[uiMergeIndex])
     473    {
     474      UInt uiSPAddr;
     475      Int iWidth = pcCU->getWidth(uiAbsPartIdx);
     476      Int iHeight = pcCU->getHeight(uiAbsPartIdx);
     477
     478      Int iNumSPInOneLine, iNumSP, iSPWidth, iSPHeight;
     479
     480      pcCU->getSPPara(iWidth, iHeight, iNumSP, iNumSPInOneLine, iSPWidth, iSPHeight);
     481
     482      for (Int iPartitionIdx = 0; iPartitionIdx < iNumSP; iPartitionIdx++)
     483      {
     484        pcCU->getSPAbsPartIdx(uiAbsPartIdx, iSPWidth, iSPHeight, iPartitionIdx, iNumSPInOneLine, uiSPAddr);
     485        pcCU->setInterDirSP(puhInterDirSP[iPartitionIdx], uiSPAddr, iSPWidth, iSPHeight);
     486        pcCU->getCUMvField( REF_PIC_LIST_0 )->setMvFieldSP(pcCU, uiSPAddr, pcMvFieldSP[2*iPartitionIdx], iSPWidth, iSPHeight);
     487        pcCU->getCUMvField( REF_PIC_LIST_1 )->setMvFieldSP(pcCU, uiSPAddr, pcMvFieldSP[2*iPartitionIdx + 1], iSPWidth, iSPHeight);
     488      }
     489    }
     490    delete pcMvFieldSP;
     491    delete puhInterDirSP;
     492#endif
     493#if !LGE_SHARP_VSP_INHERIT_F0104
    425494#if H_3D_IC
    426495    m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
     
    429498    m_pcEntropyDecoder->decodeARPW( pcCU , uiAbsPartIdx , uiDepth );
    430499#endif
     500#endif
     501
    431502    xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast );
     503#if QC_DEPTH_IV_MRG_F0125
     504    xDecompressCU(pcCU, uiAbsPartIdx, uiDepth );
     505#endif
    432506    return;
    433507  }
     
    443517    {
    444518      xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast );
     519#if QC_DEPTH_IV_MRG_F0125
     520      xDecompressCU(pcCU, uiAbsPartIdx, uiDepth );
     521#endif
    445522      return;
    446523    }
     
    452529  // prediction mode ( Intra : direction mode, Inter : Mv, reference idx )
    453530  m_pcEntropyDecoder->decodePredInfo( pcCU, uiAbsPartIdx, uiDepth, m_ppcCU[uiDepth]);
     531#if !LGE_SHARP_VSP_INHERIT_F0104
    454532#if H_3D_IC
    455533  m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
     
    458536  m_pcEntropyDecoder->decodeARPW    ( pcCU , uiAbsPartIdx , uiDepth ); 
    459537#endif 
     538#endif
    460539#if H_3D_INTER_SDC
    461540  m_pcEntropyDecoder->decodeInterSDCFlag( pcCU, uiAbsPartIdx, uiDepth );
     
    466545  setdQPFlag( bCodeDQP );
    467546  xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast );
     547#if QC_DEPTH_IV_MRG_F0125
     548  xDecompressCU(pcCU, uiAbsPartIdx, uiDepth );
     549#endif
    468550}
    469551
     
    481563{
    482564  TComPic* pcPic = pcCU->getPic();
    483  
     565#if !QC_DEPTH_IV_MRG_F0125 
    484566  Bool bBoundary = false;
    485567  UInt uiLPelX   = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiAbsPartIdx] ];
     
    516598    return;
    517599  }
    518  
     600#endif 
    519601  // Residual reconstruction
    520602  m_ppcYuvResi[uiDepth]->clear();
     
    693775    for( UInt uiX = 0; uiX < uiWidth; uiX++ )
    694776    {
     777#if LGE_PRED_RES_CODING_DLT_DOMAIN_F0159
     778        if( (isDimMode( uiLumaPredMode ) || uiLumaPredMode == HOR_IDX || uiLumaPredMode == VER_IDX || uiLumaPredMode == DC_IDX) && pcCU->getSlice()->getIsDepth() && pcCU->getSlice()->getVPS()->getUseDLTFlag(pcCU->getSlice()->getLayerIdInVps()) )
     779        {
     780            pReco    [ uiX ] = pcCU->getSlice()->getVPS()->idx2DepthValue( pcCU->getSlice()->getLayerIdInVps(), Clip3( 0, pcCU->getSlice()->getVPS()->getNumDepthValues( pcCU->getSlice()->getLayerIdInVps() ) - 1, pcCU->getSlice()->getVPS()->depthValue2idx( pcCU->getSlice()->getLayerIdInVps(), pPred[ uiX ] ) + pResi[ uiX ] ) );
     781        }
     782        else
     783        {
    695784      pReco    [ uiX ] = ClipY( pPred[ uiX ] + pResi[ uiX ] );
     785        }
     786#else
     787      pReco    [ uiX ] = ClipY( pPred[ uiX ] + pResi[ uiX ] );
     788#endif
    696789      pRecIPred[ uiX ] = pReco[ uiX ];
    697790    }
Note: See TracChangeset for help on using the changeset viewer.