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


Ignore:
Timestamp:
4 May 2015, 17:47:40 (9 years ago)
Author:
tech
Message:

Merged 14.0-dev0@1187.

File:
1 edited

Legend:

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

    r1179 r1196  
    310310#if H_3D_NBDV
    311311  DisInfo DvInfo;
    312 #if !SEC_ARP_REM_ENC_RESTRICT_K0035
    313   DvInfo.bDV = false;
    314 #endif
    315312  DvInfo.m_acNBDV.setZero();
    316313  DvInfo.m_aVIdxCan = 0;
     
    347344      if( pcCU->getSlice()->getIsDepth())
    348345      {
    349 #if SEC_ARP_REM_ENC_RESTRICT_K0035
    350346        m_ppcCU[uiDepth]->getDispforDepth(0, 0, &DvInfo);
    351 #else
    352         DvInfo.bDV = m_ppcCU[uiDepth]->getDispforDepth(0, 0, &DvInfo);
    353 #endif
    354347      }
    355348      else
     
    359352      if( pcCU->getSlice()->getDepthBasedBlkPartFlag() )  //Notes from QC: please check the condition for DoNBDV. Remove this comment once it is done.
    360353      {
    361 #if SEC_ARP_REM_ENC_RESTRICT_K0035
    362354        m_ppcCU[uiDepth]->getDisMvpCandNBDV(&DvInfo, true);
    363 #else
    364         DvInfo.bDV = m_ppcCU[uiDepth]->getDisMvpCandNBDV(&DvInfo, true);
    365 #endif
    366355      }
    367356      else
    368357#endif
    369358      {
    370 #if SEC_ARP_REM_ENC_RESTRICT_K0035
    371359        m_ppcCU[uiDepth]->getDisMvpCandNBDV(&DvInfo);
    372 #else
    373         DvInfo.bDV = m_ppcCU[uiDepth]->getDisMvpCandNBDV(&DvInfo);
    374 #endif
    375360      }
    376361#if H_3D_IV_MERGE
     
    545530    return;
    546531  }
    547 #if SEC_DEPTH_INTRA_SKIP_MODE_K0033
     532#if H_3D
    548533  m_pcEntropyDecoder->decodeDIS( pcCU, uiAbsPartIdx, uiDepth );
    549534  if(!pcCU->getDISFlag(uiAbsPartIdx))
    550535  {
    551 #else
    552 #if H_3D_SINGLE_DEPTH
    553   m_pcEntropyDecoder->decodeSingleDepthMode( pcCU, uiAbsPartIdx, uiDepth );
    554   if(!pcCU->getSingleDepthFlag(uiAbsPartIdx))
    555   {
    556 #endif
    557536#endif
    558537  m_pcEntropyDecoder->decodePredMode( pcCU, uiAbsPartIdx, uiDepth );
    559538  m_pcEntropyDecoder->decodePartSize( pcCU, uiAbsPartIdx, uiDepth );
    560539
    561 #if !HHI_MOVE_SYN_K0052
    562 #if H_3D_DIM_SDC
    563   m_pcEntropyDecoder->decodeSDCFlag( pcCU, uiAbsPartIdx, uiDepth );
    564 #endif
    565 #endif
    566540  if (pcCU->isIntra( uiAbsPartIdx ) && pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N )
    567541  {
     
    570544    if(pcCU->getIPCMFlag(uiAbsPartIdx))
    571545    {
    572 #if HHI_MOVE_SYN_K0052
    573546#if H_3D_DIM_SDC
    574547      m_pcEntropyDecoder->decodeSDCFlag( pcCU, uiAbsPartIdx, uiDepth );
    575 #endif
    576548#endif
    577549      xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast );
     
    593565  m_pcEntropyDecoder->decodeCoeff( pcCU, uiAbsPartIdx, uiDepth, uiCurrWidth, uiCurrHeight, bCodeDQP );
    594566  setdQPFlag( bCodeDQP );
    595 #if SEC_DEPTH_INTRA_SKIP_MODE_K0033
    596   }
    597 #else
    598 #if H_3D_SINGLE_DEPTH
    599   }
    600 #endif
     567#if H_3D
     568  }
    601569#endif
    602570  xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast );
     
    625593  UInt uiTPelY   = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiAbsPartIdx] ];
    626594  UInt uiBPelY   = uiTPelY + (g_uiMaxCUHeight>>uiDepth) - 1;
    627  
     595
    628596  UInt uiCurNumParts    = pcPic->getNumPartInCU() >> (uiDepth<<1);
    629597  TComSlice * pcSlice = pcCU->getPic()->getSlice(pcCU->getPic()->getCurrSliceIdx());
     
    633601    bBoundary = true;
    634602  }
    635  
     603
    636604  if( ( ( uiDepth < pcCU->getDepth( uiAbsPartIdx ) ) && ( uiDepth < g_uiMaxCUDepth - g_uiAddCUDepth ) ) || bBoundary )
    637605  {
     
    643611      uiLPelX = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiIdx] ];
    644612      uiTPelY = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiIdx] ];
    645      
     613
    646614      Bool binSlice = (pcCU->getSCUAddr()+uiIdx+uiQNumParts>pcSlice->getSliceSegmentCurStartCUAddr())&&(pcCU->getSCUAddr()+uiIdx<pcSlice->getSliceSegmentCurEndCUAddr());
    647615      if(binSlice&&( uiLPelX < pcSlice->getSPS()->getPicWidthInLumaSamples() ) && ( uiTPelY < pcSlice->getSPS()->getPicHeightInLumaSamples() ) )
     
    649617        xDecompressCU(pcCU, uiIdx, uiNextDepth );
    650618      }
    651      
     619
    652620      uiIdx += uiQNumParts;
    653621    }
     
    657625  // Residual reconstruction
    658626  m_ppcYuvResi[uiDepth]->clear();
    659  
     627
    660628  m_ppcCU[uiDepth]->copySubCU( pcCU, uiAbsPartIdx, uiDepth );
    661629
    662630  switch( m_ppcCU[uiDepth]->getPredictionMode(0) )
    663631  {
    664     case MODE_INTER:
     632  case MODE_INTER:
    665633#if H_3D_DBBP
    666       if( m_ppcCU[uiDepth]->getDBBPFlag(0) )
    667       {
    668         xReconInterDBBP( m_ppcCU[uiDepth], uiAbsPartIdx, uiDepth );
    669       }
    670       else
    671       {
     634    if( m_ppcCU[uiDepth]->getDBBPFlag(0) )
     635    {
     636      xReconInterDBBP( m_ppcCU[uiDepth], uiAbsPartIdx, uiDepth );
     637    }
     638    else
     639    {
    672640#endif
    673641#if H_3D_INTER_SDC
     
    679647      {
    680648#endif
    681       xReconInter( m_ppcCU[uiDepth], uiDepth );
     649        xReconInter( m_ppcCU[uiDepth], uiDepth );
    682650#if H_3D_INTER_SDC
    683651      }
    684652#endif
    685653#if H_3D_DBBP
    686       }
    687 #endif
    688       break;
    689     case MODE_INTRA:
    690 #if SEC_DEPTH_INTRA_SKIP_MODE_K0033
    691       if( m_ppcCU[uiDepth]->getDISFlag(0) )
    692       {
    693         xReconDIS( m_ppcCU[uiDepth], 0, uiDepth );
    694       }
     654    }
     655#endif
     656    break;
     657  case MODE_INTRA:
     658#if H_3D
     659    if( m_ppcCU[uiDepth]->getDISFlag(0) )
     660    {
     661      xReconDIS( m_ppcCU[uiDepth], 0, uiDepth );
     662    }
    695663#if H_3D_DIM_SDC
    696       else if( m_ppcCU[uiDepth]->getSDCFlag(0) )
    697       {
    698         xReconIntraSDC( m_ppcCU[uiDepth], 0, uiDepth );
    699       }
    700 #endif
    701       else
    702 #else
    703 #if H_3D_SINGLE_DEPTH
    704       if( m_ppcCU[uiDepth]->getSingleDepthFlag(0) )
    705         xReconIntraSingleDepth( m_ppcCU[uiDepth], 0, uiDepth );
    706 #if H_3D_DIM_SDC
    707       else if( m_ppcCU[uiDepth]->getSDCFlag(0) )
    708         xReconIntraSDC( m_ppcCU[uiDepth], 0, uiDepth );
    709 #endif
    710       else
    711 #else
    712 #if H_3D_DIM_SDC
    713       if( m_ppcCU[uiDepth]->getSDCFlag(0) )
    714         xReconIntraSDC( m_ppcCU[uiDepth], 0, uiDepth );
    715       else
    716 #endif
    717 #endif
     664    else if( m_ppcCU[uiDepth]->getSDCFlag(0) )
     665    {
     666      xReconIntraSDC( m_ppcCU[uiDepth], 0, uiDepth );
     667    }
     668#endif
     669    else
    718670#endif
    719671      xReconIntraQT( m_ppcCU[uiDepth], uiDepth );
    720       break;
    721     default:
    722       assert(0);
    723       break;
     672    break;
     673  default:
     674    assert(0);
     675    break;
    724676  }
    725677  if ( m_ppcCU[uiDepth]->isLosslessCoded(0) && (m_ppcCU[uiDepth]->getIPCMFlag(0) == false))
     
    727679    xFillPCMBuffer(m_ppcCU[uiDepth], uiDepth);
    728680  }
    729  
     681
    730682  xCopyToPic( m_ppcCU[uiDepth], pcPic, uiAbsPartIdx, uiDepth );
    731683}
     
    751703}
    752704
    753 #if SEC_DEPTH_INTRA_SKIP_MODE_K0033
     705#if H_3D
    754706Void TDecCu::xReconDIS( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
    755707{
     
    828780  }
    829781}
    830 #else
    831 #if H_3D_SINGLE_DEPTH
    832 Void TDecCu::xReconIntraSingleDepth( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
    833 {
    834   UInt uiWidth        = pcCU->getWidth  ( 0 );
    835   UInt uiHeight       = pcCU->getHeight ( 0 );
    836 
    837   TComYuv* pcRecoYuv  = m_ppcYuvReco[uiDepth];
    838 
    839   UInt    uiStride    = pcRecoYuv->getStride  ();
    840   Pel*    piReco      = pcRecoYuv->getLumaAddr( uiAbsPartIdx );
    841 
    842 
    843   AOF( uiWidth == uiHeight );
    844   AOF( uiAbsPartIdx == 0 );
    845 
    846   //construction of depth candidates
    847   Pel testDepth;
    848   Pel DepthNeighbours[2];
    849   Int index =0;
    850   for( Int i = 0; (i < 2) && (index<SINGLE_DEPTH_MODE_CAND_LIST_SIZE) ; i++ )
    851   {
    852     if(!pcCU->getNeighDepth (0, uiAbsPartIdx, &testDepth, i))
    853     {
    854       continue;
    855     }
    856     DepthNeighbours[index]=testDepth;
    857     index++;
    858   }
    859 
    860   if(index==0)
    861   {
    862     DepthNeighbours[index]=1<<(g_bitDepthY-1);
    863     index++;
    864   }
    865 
    866   if(index==1)
    867   {
    868     DepthNeighbours[index]=ClipY(DepthNeighbours[0] + 1 );
    869     index++;
    870   }
    871 
    872   for( UInt uiY = 0; uiY < uiHeight; uiY++ )
    873   {
    874     for( UInt uiX = 0; uiX < uiWidth; uiX++ )
    875     {
    876       piReco[ uiX ] =DepthNeighbours[(Int)pcCU->getSingleDepthValue(uiAbsPartIdx)];
    877     }
    878     piReco     += uiStride;
    879   }
    880 
    881   // clear UV
    882   UInt  uiStrideC     = pcRecoYuv->getCStride();
    883   Pel   *pRecCb       = pcRecoYuv->getCbAddr();
    884   Pel   *pRecCr       = pcRecoYuv->getCrAddr();
    885 
    886   for (Int y=0; y<uiHeight/2; y++)
    887   {
    888     for (Int x=0; x<uiWidth/2; x++)
    889     {
    890       pRecCb[x] = 1<<(g_bitDepthC-1);
    891       pRecCr[x] = 1<<(g_bitDepthC-1);
    892     }
    893 
    894     pRecCb += uiStrideC;
    895     pRecCr += uiStrideC;
    896   }
    897 }
    898 #endif
    899 #endif
    900 
     782#endif
    901783#if H_3D_INTER_SDC
    902784Void TDecCu::xReconInterSDC( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
     
    962844  // compute mask by segmenting depth block
    963845  Bool pMask[MAX_CU_SIZE*MAX_CU_SIZE];
    964 #if HS_DBBP_CLEAN_K0048
    965846  Bool bValidMask = m_pcPrediction->getSegmentMaskFromDepth(pDepthPels, uiDepthStride, pcCU->getWidth(0), pcCU->getHeight(0), pMask, pcCU);
    966 #else
    967   Bool bValidMask = m_pcPrediction->getSegmentMaskFromDepth(pDepthPels, uiDepthStride, pcCU->getWidth(0), pcCU->getHeight(0), pMask);
    968 #endif
    969847  AOF(bValidMask);
    970848 
    971   DBBPTmpData* pDBBPTmpData = pcCU->getDBBPTmpData();
     849  DbbpTmpData* pDBBPTmpData = pcCU->getDBBPTmpData();
    972850  TComYuv* apSegPredYuv[2] = { m_ppcYuvReco[uiDepth], m_ppcYuvRecoDBBP[uiDepth] };
    973851 
Note: See TracChangeset for help on using the changeset viewer.