Ignore:
Timestamp:
31 Dec 2012, 18:33:14 (12 years ago)
Author:
mitsubishi-htm
Message:

A final release, as planned

  • Migrate to HTM 5.1
  • For VC project files, only VC9 file is updated
  • To be used as an additional anchor for CE1.h for 3rd JCTVC meeting at Geneva
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-4.0.1-VSP-dev0/source/Lib/TLibDecoder/TDecEntropy.cpp

    r193 r213  
    7474}
    7575
     76#if LGE_ILLUCOMP_B0045
     77Void TDecEntropy::decodeICFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
     78{
     79  pcCU->setICFlagSubParts( false , uiAbsPartIdx, 0, uiDepth );
     80
     81  if (pcCU->isIntra(uiAbsPartIdx) || (pcCU->getSlice()->getViewId() == 0) || pcCU->getSlice()->getSPS()->isDepth())
     82  {
     83    return;
     84  }
     85
     86  if(!pcCU->getSlice()->getApplyIC())
     87    return;
     88
     89  if(pcCU->isICFlagRequired(uiAbsPartIdx))
     90    m_pcEntropyDecoderIf->parseICFlag( pcCU, uiAbsPartIdx, uiDepth );
     91}
     92#endif
    7693/** decode merge index
    7794 * \param pcCU
     
    137154{
    138155  m_pcEntropyDecoderIf->parsePredMode( pcCU, uiAbsPartIdx, uiDepth );
     156 
     157#if RWTH_SDC_DLT_B0036
     158  // if B-Slice, code SDC flag later
     159  if( !pcCU->getSlice()->isInterB() && pcCU->isIntra(uiAbsPartIdx) && pcCU->getSlice()->getSPS()->isDepth() )
     160  {
     161    // decode SDC flag
     162    decodeSDCFlag(pcCU, uiAbsPartIdx, uiDepth);
     163  }
     164#endif
    139165}
    140166
    141167Void TDecEntropy::decodePartSize( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
    142168{
     169#if RWTH_SDC_DLT_B0036
     170  if( !pcCU->getSlice()->isInterB() && pcCU->isIntra(uiAbsPartIdx) && pcCU->getSDCFlag(uiAbsPartIdx)  )
     171  {
     172    pcCU->setPartSizeSubParts( SIZE_2Nx2N, uiAbsPartIdx, uiDepth );
     173    pcCU->setSizeSubParts( g_uiMaxCUWidth>>uiDepth, g_uiMaxCUHeight>>uiDepth, uiAbsPartIdx, uiDepth );
     174    return;
     175  }
     176#endif
     177 
    143178  m_pcEntropyDecoderIf->parsePartSize( pcCU, uiAbsPartIdx, uiDepth );
     179 
     180#if RWTH_SDC_DLT_B0036
     181  if( pcCU->getSlice()->isInterB() && pcCU->getSlice()->getSPS()->isDepth() && pcCU->isIntra(uiAbsPartIdx) )
     182  {
     183    // decode SDC flag
     184    decodeSDCFlag(pcCU, uiAbsPartIdx, uiDepth);
     185   
     186    if( pcCU->getSDCFlag(uiAbsPartIdx) )
     187    {
     188      // part size is also known for SDC intra
     189      pcCU->setPartSizeSubParts( SIZE_2Nx2N, uiAbsPartIdx, uiDepth );
     190      pcCU->setSizeSubParts( g_uiMaxCUWidth>>uiDepth, g_uiMaxCUHeight>>uiDepth, uiAbsPartIdx, uiDepth );
     191    }
     192  }
     193#endif
    144194}
    145195
    146196Void TDecEntropy::decodePredInfo    ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, TComDataCU* pcSubCU )
    147197{
     198#if RWTH_SDC_DLT_B0036
     199  if( pcCU->getSDCFlag(uiAbsPartIdx) )
     200  {
     201    decodeSDCPredMode(pcCU, uiAbsPartIdx, uiDepth);
     202    return;
     203  }
     204#endif
     205 
    148206  PartSize eMode = pcCU->getPartitionSize( uiAbsPartIdx );
    149207 
     
    186244    return;
    187245  }
     246 
     247#if RWTH_SDC_DLT_B0036
     248  if( pcCU->getSDCFlag(uiAbsPartIdx) )
     249  {
     250    return;
     251  }
     252#endif
    188253 
    189254  m_pcEntropyDecoderIf->parseIPCMInfo( pcCU, uiAbsPartIdx, uiDepth );
     
    449514#endif
    450515  }
     516#if SHARP_INTERVIEW_DECOUPLE_B0111
     517  pcSubCU->fillMvpCand(uiPartIdx, uiPartAddr, eRefList, iRefIdx, pAMVPInfo, iMVPIdx);
     518#else
    451519  pcSubCU->fillMvpCand(uiPartIdx, uiPartAddr, eRefList, iRefIdx, pAMVPInfo);
     520#endif
    452521  pcSubCU->setMVPNumSubParts(pAMVPInfo->iN, eRefList, uiPartAddr, uiPartIdx, uiDepth);
    453522  pcSubCU->setMVPIdxSubParts( iMVPIdx, eRefList, uiPartAddr, uiPartIdx, uiDepth );
     
    917986#endif
    918987 
     988#if RWTH_SDC_DLT_B0036
     989  if( pcCU->getSDCAvailable(uiAbsPartIdx) && pcCU->getSDCFlag( uiAbsPartIdx ) )
     990  {
     991    assert( pcCU->getPartitionSize(uiAbsPartIdx) == SIZE_2Nx2N );
     992    assert( pcCU->getTransformIdx(uiAbsPartIdx) == 0 );
     993    assert( pcCU->getCbf(uiAbsPartIdx, TEXT_LUMA) == 1 );
     994    assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_U) == 1 );
     995    assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_V) == 1 );
     996   
     997    decodeSDCResidualData(pcCU, uiAbsPartIdx, uiDepth);
     998    return;
     999  }
     1000#endif
     1001 
    9191002  if( pcCU->isIntra(uiAbsPartIdx) )
    9201003  {
     
    9521035#endif // !UNIFIED_TRANSFORM_TREE
    9531036  }
     1037
     1038#if FIX_MPI_B0065
     1039  if( pcCU->getPredictionMode(uiAbsPartIdx) == MODE_INTER && pcCU->getMergeFlag( uiAbsPartIdx ) && pcCU->getMergeIndex( uiAbsPartIdx ) == 0 && pcCU->getPartitionSize(uiAbsPartIdx) == SIZE_2Nx2N &&  pcCU->getTextureModeDepth( uiAbsPartIdx ) != -1  )
     1040  {
     1041    TComDataCU *pcTextureCU = pcCU->getSlice()->getTexturePic()->getCU( pcCU->getAddr() );
     1042    if( uiDepth == pcTextureCU->getDepth(uiAbsPartIdx))
     1043    {
     1044      PartSize partSize = pcTextureCU->getPartitionSize(uiAbsPartIdx);
     1045      pcCU->setPartSizeSubParts( partSize, uiAbsPartIdx, uiDepth );
     1046    }
     1047    else
     1048    {
     1049      pcCU->setPartSizeSubParts( SIZE_NxN, uiAbsPartIdx, uiDepth );
     1050    }
     1051  }
     1052#endif
     1053
    9541054#if UNIFIED_TRANSFORM_TREE
    9551055  xDecodeTransform( pcCU, uiLumaOffset, uiChromaOffset, uiAbsPartIdx, uiAbsPartIdx, uiDepth, uiWidth, uiHeight, 0, 0, temp, temp1, temp2, bCodeDQP );
     
    9571057  xDecodeCoeff( pcCU, uiLumaOffset, uiChromaOffset, uiAbsPartIdx, uiDepth, uiWidth, uiHeight, 0, uiLumaTrMode, bCodeDQP );
    9581058#endif // UNIFIED_TRANSFORM_TREE
    959 }
     1059
     1060#if FIX_MPI_B0065
     1061  if( pcCU->getPredictionMode(uiAbsPartIdx) == MODE_INTER && pcCU->getMergeFlag( uiAbsPartIdx ) && pcCU->getMergeIndex( uiAbsPartIdx ) == 0 && pcCU->getPartitionSize(uiAbsPartIdx) != SIZE_2Nx2N &&  pcCU->getTextureModeDepth( uiAbsPartIdx ) != -1 )
     1062  {
     1063    pcCU->setPartSizeSubParts( SIZE_2Nx2N, uiAbsPartIdx, uiDepth ); 
     1064  }
     1065#endif
     1066}
     1067
     1068#if RWTH_SDC_DLT_B0036
     1069Void TDecEntropy::decodeSDCPredMode( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
     1070{
     1071  assert( pcCU->getSlice()->getSPS()->isDepth() );
     1072  assert( pcCU->getPartitionSize(uiAbsPartIdx) == SIZE_2Nx2N );
     1073 
     1074  m_pcEntropyDecoderIf->parseSDCPredMode(pcCU, uiAbsPartIdx, uiDepth );
     1075}
     1076
     1077Void TDecEntropy::decodeSDCFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
     1078{
     1079  assert( pcCU->getSlice()->getSPS()->isDepth() );
     1080 
     1081  m_pcEntropyDecoderIf->parseSDCFlag(pcCU, uiAbsPartIdx, uiDepth );
     1082}
     1083
     1084Void TDecEntropy::decodeSDCResidualData( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
     1085{
     1086  assert( pcCU->getSlice()->getSPS()->isDepth() );
     1087  assert( pcCU->getSDCFlag(uiAbsPartIdx) );
     1088 
     1089  // number of segments depends on prediction mode for INTRA
     1090  UInt uiNumSegments = 2;
     1091  UInt uiLumaPredMode = pcCU->getLumaIntraDir( uiAbsPartIdx );
     1092  if( pcCU->getPredictionMode(uiAbsPartIdx) == MODE_INTRA && (uiLumaPredMode == DC_IDX || uiLumaPredMode == PLANAR_IDX) )
     1093    uiNumSegments = 1;
     1094 
     1095  // decode residual data for each segment
     1096  for( UInt uiSeg = 0; uiSeg < uiNumSegments; uiSeg++ )
     1097    m_pcEntropyDecoderIf->parseSDCResidualData(pcCU, uiAbsPartIdx, uiDepth, uiSeg);
     1098}
     1099#endif
    9601100
    9611101//! \}
Note: See TracChangeset for help on using the changeset viewer.