Changeset 724 in 3DVCSoftware for trunk/source/Lib/TLibDecoder


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

Merged HTM-8.2-dev0@723.

Location:
trunk/source/Lib/TLibDecoder
Files:
7 edited

Legend:

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

    r655 r724  
    12451245    pcVPS->setARPStepNum( i, 1 );
    12461246#endif 
     1247#if MTK_SPIVMP_F0110
     1248    pcVPS->setSubPULog2Size(i, 0);
     1249#endif
    12471250    if ( i != 0 )
    12481251    {
     
    12511254#if H_3D_IV_MERGE
    12521255        READ_FLAG( uiCode, "iv_mv_pred_flag[i]");          pcVPS->setIvMvPredFlag         ( i, uiCode == 1 ? true : false );
     1256#if MTK_SPIVMP_F0110
     1257        READ_UVLC (uiCode, "log2_sub_PU_size_minus2");     pcVPS->setSubPULog2Size(i, uiCode+2);
     1258#endif
    12531259#endif
    12541260#if H_3D_ARP
     
    12651271      else
    12661272      {
    1267 
     1273#if QC_DEPTH_IV_MRG_F0125 && H_3D_IV_MERGE
     1274        if(i!=1)
     1275        {
     1276          READ_FLAG( uiCode, "iv_mv_pred_flag[i]");          pcVPS->setIvMvPredFlag         ( i, uiCode == 1 ? true : false );
     1277        }
     1278#endif
     1279#if MTK_SPIVMP_F0110
     1280        if (i!=1)
     1281        {
     1282          READ_UVLC (uiCode, "log2_sub_PU_size_minus2");     pcVPS->setSubPULog2Size(i, uiCode+2);
     1283        }
     1284#endif
     1285#if SEC_MPI_ENABLING_MERGE_F0150
     1286        READ_FLAG( uiCode, "mpi_flag[i]" );             pcVPS->setMPIFlag( i, uiCode == 1 ? true : false );
     1287#endif
    12681288        READ_FLAG( uiCode, "vps_depth_modes_flag[i]" );             pcVPS->setVpsDepthModesFlag( i, uiCode == 1 ? true : false );
    12691289        //          READ_FLAG( uiCode, "lim_qt_pred_flag[i]");                  pcVPS->setLimQtPreFlag     ( i, uiCode == 1 ? true : false );
     
    17951815    }
    17961816#if H_3D_IC
     1817#if SEC_ONLY_TEXTURE_IC_F0151
     1818    else if( rpcSlice->getViewIndex() && ( rpcSlice->getSliceType() == P_SLICE || rpcSlice->getSliceType() == B_SLICE ) && !rpcSlice->getIsDepth())
     1819#else
    17971820    else if( rpcSlice->getViewIndex() && ( rpcSlice->getSliceType() == P_SLICE || rpcSlice->getSliceType() == B_SLICE ) )
     1821#endif
    17981822    {
    17991823      UInt uiCodeTmp = 0;
     
    18131837      READ_UVLC( uiCode, "five_minus_max_num_merge_cand");
    18141838#if H_3D_IV_MERGE
     1839#if SEC_MPI_ENABLING_MERGE_F0150
     1840      if(rpcSlice->getIsDepth())
     1841      {
     1842        Bool bMPIFlag = rpcSlice->getVPS()->getMPIFlag( rpcSlice->getLayerIdInVps() ) ;
     1843        Bool ivMvPredFlag = rpcSlice->getVPS()->getIvMvPredFlag( rpcSlice->getLayerIdInVps() ) ;
     1844        rpcSlice->setMaxNumMergeCand(( ( bMPIFlag || ivMvPredFlag ) ? MRG_MAX_NUM_CANDS_MEM : MRG_MAX_NUM_CANDS) - uiCode);
     1845      }
     1846      else
     1847      {
     1848        Bool ivMvPredFlag = rpcSlice->getVPS()->getIvMvPredFlag( rpcSlice->getLayerIdInVps() ) ;
     1849        rpcSlice->setMaxNumMergeCand(( ivMvPredFlag ? MRG_MAX_NUM_CANDS_MEM : MRG_MAX_NUM_CANDS) - uiCode);
     1850      }
     1851#else
    18151852      Bool ivMvPredFlag = rpcSlice->getVPS()->getIvMvPredFlag( rpcSlice->getLayerIdInVps() ) ;
    18161853      rpcSlice->setMaxNumMergeCand(( ivMvPredFlag ? MRG_MAX_NUM_CANDS_MEM : MRG_MAX_NUM_CANDS) - uiCode);
     1854#endif
    18171855#else
    18181856      rpcSlice->setMaxNumMergeCand(MRG_MAX_NUM_CANDS - uiCode);
  • 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    }
  • trunk/source/Lib/TLibDecoder/TDecEntropy.cpp

    r655 r724  
    111111  pcCU->setICFlagSubParts( false , uiAbsPartIdx, 0, uiDepth );
    112112
     113#if SEC_ONLY_TEXTURE_IC_F0151
     114  if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) || pcCU->getSlice()->getIsDepth() )
     115#else
    113116  if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) )
     117#endif
    114118  {
    115119    return;
     
    209213  UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS];
    210214#endif
    211 
     215#if MTK_SPIVMP_F0110
     216  Bool bSPIVMPFlag[MRG_MAX_NUM_CANDS_MEM];
     217  TComMvField*  pcMvFieldSP;
     218  UChar* puhInterDirSP;
     219  pcMvFieldSP = new TComMvField[pcCU->getPic()->getPicSym()->getNumPartition()*2];
     220  puhInterDirSP = new UChar[pcCU->getPic()->getPicSym()->getNumPartition()];
     221#endif
    212222  for ( UInt ui = 0; ui < pcCU->getSlice()->getMaxNumMergeCand(); ui++ )
    213223  {
     
    235245      decodeMergeIndex( pcCU, uiPartIdx, uiSubPartIdx, uiDepth );
    236246      UInt uiMergeIndex = pcCU->getMergeIndex(uiSubPartIdx);
     247#if LGE_SHARP_VSP_INHERIT_F0104
     248#if H_3D_IC
     249      decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
     250#endif
     251#if H_3D_ARP
     252      decodeARPW  ( pcCU, uiAbsPartIdx, uiDepth );
     253#endif
     254#endif
    237255      if ( pcCU->getSlice()->getPPS()->getLog2ParallelMergeLevelMinus2() && ePartSize != SIZE_2Nx2N && pcSubCU->getWidth( 0 ) <= 8 )
    238256      {
     
    244262          memset(vspFlag, 0, sizeof(Int)*MRG_MAX_NUM_CANDS_MEM);
    245263          InheritedVSPDisInfo inheritedVSPDisInfo[MRG_MAX_NUM_CANDS_MEM];
     264#if MTK_SPIVMP_F0110
     265          memset(bSPIVMPFlag, false, sizeof(Bool)*MRG_MAX_NUM_CANDS_MEM);
     266#endif
     267#if ETRIKHU_MERGE_REUSE_F0093
     268          pcSubCU->initAvailableFlags();
     269          pcSubCU->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand);
     270          pcSubCU->xGetInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, vspFlag, inheritedVSPDisInfo
     271#if MTK_SPIVMP_F0110
     272            , bSPIVMPFlag, pcMvFieldSP, puhInterDirSP
     273#endif
     274            , numValidMergeCand );
     275#else
    246276          pcSubCU->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, vspFlag, inheritedVSPDisInfo, numValidMergeCand );
     277#endif
    247278          pcCU->setVSPFlagSubParts( vspFlag[uiMergeIndex], uiSubPartIdx, uiPartIdx, uiDepth );
    248279
     
    252283          }
    253284#else
     285#if ETRIKHU_MERGE_REUSE_F0093
     286          pcSubCU->initAvailableFlags();
     287          pcSubCU->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand);
     288          pcSubCU->xGetInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand );
     289
     290#else
    254291          pcSubCU->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand );
     292#endif
    255293#endif
    256294          isMerged = true;
     
    265303        memset(vspFlag, 0, sizeof(Int)*MRG_MAX_NUM_CANDS_MEM);
    266304        InheritedVSPDisInfo inheritedVSPDisInfo[MRG_MAX_NUM_CANDS_MEM];
     305#if MTK_SPIVMP_F0110
     306        memset(bSPIVMPFlag, false, sizeof(Bool)*MRG_MAX_NUM_CANDS_MEM);
     307#endif
     308#if ETRIKHU_MERGE_REUSE_F0093
     309        pcSubCU->initAvailableFlags();
     310        pcSubCU->getInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
     311        pcSubCU->xGetInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, vspFlag, inheritedVSPDisInfo
     312#if MTK_SPIVMP_F0110
     313          , bSPIVMPFlag, pcMvFieldSP, puhInterDirSP
     314#endif
     315          ,numValidMergeCand, uiMergeIndex );
     316#else
    267317        pcSubCU->getInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, vspFlag, inheritedVSPDisInfo,numValidMergeCand, uiMergeIndex );
     318#endif
    268319        pcCU->setVSPFlagSubParts( vspFlag[uiMergeIndex], uiSubPartIdx, uiPartIdx, uiDepth );
    269320        if(vspFlag[uiMergeIndex])
     
    272323        }
    273324#else
     325#if ETRIKHU_MERGE_REUSE_F0093
     326        pcSubCU->initAvailableFlags();
    274327        pcSubCU->getInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
     328        pcSubCU->xGetInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
     329#else
     330        pcSubCU->getInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
     331#endif
    275332#endif
    276333      }
     
    288345        }
    289346      }
     347#if MTK_SPIVMP_F0110
     348      pcCU->setSPIVMPFlagSubParts(bSPIVMPFlag[uiMergeIndex], uiSubPartIdx, uiPartIdx, uiDepth ); 
     349      if (bSPIVMPFlag[uiMergeIndex] != 0)
     350      {
     351        Int iWidth, iHeight;
     352        UInt uiIdx;
     353        pcCU->getPartIndexAndSize( uiPartIdx, uiIdx, iWidth, iHeight, uiSubPartIdx, true );
     354
     355        UInt uiSPAddr;
     356
     357        Int iNumSPInOneLine, iNumSP, iSPWidth, iSPHeight;
     358
     359        pcCU->getSPPara(iWidth, iHeight, iNumSP, iNumSPInOneLine, iSPWidth, iSPHeight);
     360
     361        for (Int iPartitionIdx = 0; iPartitionIdx < iNumSP; iPartitionIdx++)
     362        {
     363          pcCU->getSPAbsPartIdx(uiSubPartIdx, iSPWidth, iSPHeight, iPartitionIdx, iNumSPInOneLine, uiSPAddr);
     364          pcCU->setInterDirSP(puhInterDirSP[iPartitionIdx], uiSPAddr, iSPWidth, iSPHeight);
     365          pcCU->getCUMvField( REF_PIC_LIST_0 )->setMvFieldSP(pcCU, uiSPAddr, pcMvFieldSP[2*iPartitionIdx], iSPWidth, iSPHeight);
     366          pcCU->getCUMvField( REF_PIC_LIST_1 )->setMvFieldSP(pcCU, uiSPAddr, pcMvFieldSP[2*iPartitionIdx + 1], iSPWidth, iSPHeight);
     367        }
     368      }
     369#endif
    290370    }
    291371    else
     
    301381        }
    302382      }
     383#if LGE_SHARP_VSP_INHERIT_F0104
     384#if H_3D_IC
     385      decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
     386#endif
     387#if H_3D_ARP
     388      decodeARPW  ( pcCU, uiAbsPartIdx, uiDepth );
     389#endif
     390#endif
    303391    }
    304392#if H_3D_VSP
     
    313401    }
    314402  }
     403#if MTK_SPIVMP_F0110
     404  delete pcMvFieldSP;
     405  delete puhInterDirSP;
     406#endif
    315407  return;
    316408}
  • trunk/source/Lib/TLibDecoder/TDecSbac.cpp

    r655 r724  
    8989#if H_3D_DIM_DMM
    9090, m_cDmm1DataSCModel          ( 1,             1,               NUM_DMM1_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
     91#if !SEC_DMM3_RBC_F0147
    9192, m_cDmm3DataSCModel          ( 1,             1,               NUM_DMM3_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
     93#endif
    9294#endif
    9395#if H_3D_DIM_RBC
     
    176178#if H_3D_DIM_DMM
    177179  m_cDmm1DataSCModel.initBuffer          ( sliceType, qp, (UChar*)INIT_DMM1_DATA );
     180#if !SEC_DMM3_RBC_F0147
    178181  m_cDmm3DataSCModel.initBuffer          ( sliceType, qp, (UChar*)INIT_DMM3_DATA );
     182#endif
    179183#endif
    180184#if H_3D_DIM_RBC
     
    249253#if H_3D_DIM_DMM
    250254  m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
     255#if !SEC_DMM3_RBC_F0147
    251256  m_cDmm3DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM3_DATA );
     257#endif
    252258#endif
    253259#if H_3D_DIM_RBC
     
    408414}
    409415
     416#if QC_DIM_DELTADC_UNIFY_F0132
     417Void TDecSbac::xParseDimDeltaDC( Pel& rValDeltaDC, UInt uiNumSeg )
     418{
     419  UInt absValDeltaDC = 0;
     420  xReadExGolombLevel( absValDeltaDC, m_cDdcDataSCModel.get(0, 0, 0) );
     421  rValDeltaDC = (Pel)absValDeltaDC + ( uiNumSeg > 1 ? 0 : 1 );
     422
     423  if( rValDeltaDC != 0 )
     424  {
     425    UInt uiSign;
     426    m_pcTDecBinIf->decodeBinEP( uiSign );
     427    if ( uiSign )
     428    {
     429      rValDeltaDC = -rValDeltaDC;
     430    }
     431  }
     432}
     433#else
    410434Void TDecSbac::xParseDimDeltaDC( Pel& rValDeltaDC, UInt dimType )
    411435{
     
    424448  }
    425449}
     450#endif
     451
    426452#if H_3D_DIM_DMM
    427453Void TDecSbac::xParseDmm1WedgeIdx( UInt& ruiTabIdx, Int iNumBit )
     
    435461  ruiTabIdx = uiIdx;
    436462}
    437 
     463#if !SEC_DMM3_RBC_F0147
    438464Void TDecSbac::xParseDmm3WedgeIdx( UInt& ruiIntraIdx, Int iNumBit )
    439465{
     
    446472  ruiIntraIdx = uiIdx;
    447473}
     474#endif
    448475#endif
    449476#if H_3D_DIM_RBC
     
    11401167      pcCU->setDmmWedgeTabIdxSubParts( uiTabIdx, dimType, absPartIdx, depth );
    11411168    } break;
     1169#if !SEC_DMM3_RBC_F0147
    11421170  case( DMM3_IDX ):
    11431171    {
     
    11461174      pcCU->setDmm3IntraTabIdxSubParts( uiIntraIdx, absPartIdx, depth );
    11471175    } break;
     1176#endif
    11481177  case( DMM4_IDX ): break;
    11491178#endif
     
    11571186  }
    11581187
    1159 #if H_3D_DIM_SDC
     1188#if H_3D_DIM_SDC && !QC_DIM_DELTADC_UNIFY_F0132
    11601189  if( pcCU->getSDCFlag(absPartIdx) )
    11611190  {
     
    11731202  {
    11741203#endif
     1204#if QC_DIM_DELTADC_UNIFY_F0132
     1205    if( dimType < DIM_NUM_TYPE || pcCU->getSDCFlag( absPartIdx ) )
     1206#else
    11751207    if( dimType < DIM_NUM_TYPE )
     1208#endif
    11761209    {
    11771210      UInt symbol;
     1211#if QC_DIM_DELTADC_UNIFY_F0132
     1212      UInt uiNumSegments = ( dir == PLANAR_IDX ) ? 1 : 2;
     1213
     1214      if( pcCU->getSDCFlag( absPartIdx ) )
     1215      {
     1216        assert(pcCU->getPartitionSize(absPartIdx)==SIZE_2Nx2N);
     1217        pcCU->setTrIdxSubParts(0, absPartIdx, depth);
     1218        pcCU->setCbfSubParts(1, 1, 1, absPartIdx, depth);
     1219      }
     1220
     1221      m_pcTDecBinIf->decodeBin( symbol, m_cDdcFlagSCModel.get(0, 0, uiNumSegments-1) );
     1222
     1223      if( symbol )
     1224      {
     1225        if( !pcCU->getSDCFlag( absPartIdx ) )
     1226        {
     1227          dir += symbol;
     1228        }
     1229      }
     1230      for( UInt segment = 0; segment < uiNumSegments; segment++ )
     1231      {
     1232        Pel valDeltaDC = 0;
     1233        if( symbol )
     1234        {
     1235          xParseDimDeltaDC( valDeltaDC, uiNumSegments );
     1236        }
     1237
     1238        if( pcCU->getSDCFlag( absPartIdx ) )
     1239        {
     1240          pcCU->setSDCSegmentDCOffset( valDeltaDC, segment, absPartIdx );
     1241        }
     1242        else
     1243        {
     1244          pcCU->setDimDeltaDC( dimType, segment, absPartIdx, valDeltaDC );
     1245        }
     1246      }
     1247#else
    11781248      m_pcTDecBinIf->decodeBin( symbol, m_cDdcFlagSCModel.get(0, 0, (RBC_IDX == dimType) ? 1 : 0) );
    11791249      if( symbol )
     
    11871257        }
    11881258      }
    1189     }
    1190 #if H_3D_DIM_SDC
     1259#endif
     1260    }
     1261#if H_3D_DIM_SDC && !QC_DIM_DELTADC_UNIFY_F0132
    11911262  }
    11921263#endif
     
    12181289  else if( puIdx == 0 )
    12191290  {
     1291#if SEC_DMM3_RBC_F0147
     1292    while( binNum < 1 && symbol )
     1293#else
    12201294    while( binNum < 3 && symbol )
     1295#endif
    12211296    {
    12221297      ctxDepthMode = puIdx*3 + ((binNum >= 2) ? 2 : binNum);
     
    12251300      binNum++;
    12261301    }
     1302#if SEC_DMM3_RBC_F0147
     1303    if( modeCode == 0 ) { dir = 0;                       sdcFlag = 0;}
     1304    else if( modeCode == 1 ) { dir = (2*DMM1_IDX+DIM_OFFSET); sdcFlag = 0;}
     1305#else
    12271306         if( modeCode == 0 ) { dir = 0;                       sdcFlag = 0;}
    12281307    else if( modeCode == 2 ) { dir = (2*DMM1_IDX+DIM_OFFSET); sdcFlag = 0;}
    12291308    else if( modeCode == 6 ) { dir = (2*DMM3_IDX+DIM_OFFSET); sdcFlag = 0;}
    12301309    else if( modeCode == 7 ) { dir = (2* RBC_IDX+DIM_OFFSET); sdcFlag = 0;}
     1310#endif
    12311311  }
    12321312  else
    12331313  {
     1314#if SEC_DMM3_RBC_F0147
     1315    while( binNum < 4 && symbol )
     1316    {
     1317      ctxDepthMode = puIdx*3 + ((binNum >= 2) ? 2 : binNum);
     1318      m_pcTDecBinIf->decodeBin( symbol, m_cDepthIntraModeSCModel.get(0,0,ctxDepthMode) );
     1319      modeCode = (modeCode<<1) + symbol;
     1320      binNum++;
     1321    }
     1322    if ( modeCode == 0 )        { dir =  PLANAR_IDX;             sdcFlag = 1;}
     1323    else if ( modeCode == 2 )   { dir = 5;                       sdcFlag = 0;}
     1324    else if ( modeCode == 6 )   { dir = (2*DMM1_IDX+DIM_OFFSET); sdcFlag = 1;}
     1325    else if ( modeCode == 14 )  { dir = (2*DMM1_IDX+DIM_OFFSET); sdcFlag = 0;}
     1326    else if ( modeCode == 15 )  { dir = (2*DMM4_IDX+DIM_OFFSET); sdcFlag = 0;}
     1327#else
    12341328    UInt maxBinNum = 0;
    12351329    m_pcTDecBinIf->decodeBinEP(symbol);
     
    12631357      else if ( modeCode == 3 )  { dir = (2*DMM4_IDX+DIM_OFFSET); sdcFlag = 0;}
    12641358    }
     1359#endif
    12651360  }
    12661361  pcCU->setLumaIntraDirSubParts( (UChar)dir, absPartIdx, depth );
  • trunk/source/Lib/TLibDecoder/TDecSbac.h

    r655 r724  
    9999#if H_3D_DIM
    100100  Void  xReadExGolombLevel   ( UInt& ruiSymbol, ContextModel& rcSCModel  );
     101#if QC_DIM_DELTADC_UNIFY_F0132
     102  Void  xParseDimDeltaDC     ( Pel& rValDeltaDC, UInt uiNumSeg );
     103#else
    101104  Void  xParseDimDeltaDC     ( Pel& rValDeltaDC, UInt dimType );
     105#endif
    102106#if H_3D_DIM_DMM
    103107  Void  xParseDmm1WedgeIdx   ( UInt& ruiTabIdx, Int iNumBit );
     108#if !SEC_DMM3_RBC_F0147
    104109  Void  xParseDmm3WedgeIdx   ( UInt& ruiIntraIdx, Int iNumBit );
     110#endif
    105111#endif
    106112#if H_3D_DIM_RBC
     
    213219#if H_3D_DIM_DMM
    214220  ContextModel3DBuffer m_cDmm1DataSCModel;
     221#if !SEC_DMM3_RBC_F0147
    215222  ContextModel3DBuffer m_cDmm3DataSCModel;
     223#endif
    216224#endif
    217225#if H_3D_DIM_RBC
  • trunk/source/Lib/TLibDecoder/TDecTop.cpp

    r655 r724  
    282282}
    283283
     284#if QC_DEPTH_IV_MRG_F0125
     285Void
     286CamParsCollector::copyCamParamForSlice( TComSlice* pcSlice )
     287{
     288  UInt uiViewIndex = pcSlice->getViewIndex();
     289
     290  pcSlice->getSPS()->initCamParaSPS( uiViewIndex, m_uiCamParsCodedPrecision, m_bCamParsVaryOverTime, m_aaiCodedScale, m_aaiCodedOffset );
     291
     292  if( m_bCamParsVaryOverTime )
     293  {
     294    pcSlice->setCamparaSlice( m_aaiCodedScale, m_aaiCodedOffset );
     295  }
     296}
     297#endif
     298
    284299Bool
    285300CamParsCollector::xIsComplete()
     
    951966    pcSlice->setRefPicList     ( tempRefPicLists, usedAsLongTerm, numPocTotalCurr, true );
    952967#if H_3D_ARP
     968#if SHARP_ARP_REF_CHECK_F0105
     969    pcSlice->setARPStepNum(m_ivPicLists);
     970#else
    953971    pcSlice->setARPStepNum();
     972#endif
    954973    if( pcSlice->getARPStepNum() > 1 )
    955974    {
     
    10531072  }
    10541073
     1074#if QC_DEPTH_IV_MRG_F0125
     1075  if( pcSlice->getIsDepth() && m_pcCamParsCollector )
     1076  {
     1077    m_pcCamParsCollector->copyCamParamForSlice( pcSlice );
     1078  }
     1079#endif
     1080
    10551081  //  Decode a picture
    10561082  m_cGopDecoder.decompressSlice(nalu.m_Bitstream, pcPic);
     
    10601086    m_pcCamParsCollector->setSlice( pcSlice );
    10611087  }
     1088#if QC_DEPTH_IV_MRG_F0125
     1089  if( pcSlice->getIsDepth() )
     1090  {
     1091    pcSlice->getSPS()->setHasCamParInSliceHeader( false );
     1092  }
     1093#endif
    10621094#endif
    10631095  m_bFirstSliceInPicture = false;
  • trunk/source/Lib/TLibDecoder/TDecTop.h

    r655 r724  
    7777  Bool  isInitialized() const     { return m_bInitialized; }
    7878  Int**** getBaseViewShiftLUTI()  { return m_aiBaseViewShiftLUT;   }
     79
     80#if QC_DEPTH_IV_MRG_F0125
     81  Void  copyCamParamForSlice( TComSlice* pcSlice );
     82#endif
    7983
    8084private:
Note: See TracChangeset for help on using the changeset viewer.