Ignore:
Timestamp:
29 Aug 2013, 13:55:40 (11 years ago)
Author:
tech
Message:

Merged dev2: DEV-2.0-LG@595

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-DEV-2.0-dev0/source/Lib/TLibDecoder/TDecSbac.cpp

    r541 r598  
    100100#endif
    101101#endif
     102#if LGE_INTER_SDC_E0156
     103, m_cInterSDCFlagSCModel             ( 1,             1,  NUM_INTER_SDC_FLAG_CTX           , m_contextModels + m_numContextModels, m_numContextModels)
     104, m_cInterSDCResidualSCModel         ( 1,             1,  NUM_INTER_SDC_RESIDUAL_CTX       , m_contextModels + m_numContextModels, m_numContextModels)
     105, m_cInterSDCResidualSignFlagSCModel ( 1,             1,  NUM_INTER_SDC_SIGN_FLAG_CTX      , m_contextModels + m_numContextModels, m_numContextModels)
     106#endif
    102107{
    103108  assert( m_numContextModels <= MAX_NUM_CTX_MOD );
     
    182187  m_cSDCResidualSCModel.initBuffer        ( sliceType, qp, (UChar*)INIT_SDC_RESIDUAL );
    183188#endif
     189#endif
     190#if LGE_INTER_SDC_E0156
     191  m_cInterSDCFlagSCModel.initBuffer       ( sliceType, qp, (UChar*)INIT_INTER_SDC_FLAG );
     192  m_cInterSDCResidualSCModel.initBuffer   ( sliceType, qp, (UChar*)INIT_INTER_SDC_RESIDUAL );
     193  m_cInterSDCResidualSignFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_INTER_SDC_SIGN_FLAG );
    184194#endif
    185195  m_uiLastDQpNonZero  = 0;
     
    251261  m_cSDCResidualSCModel.initBuffer        ( eSliceType, iQp, (UChar*)INIT_SDC_RESIDUAL );
    252262#endif
     263#endif
     264#if LGE_INTER_SDC_E0156
     265  m_cInterSDCFlagSCModel.initBuffer       ( eSliceType, iQp, (UChar*)INIT_INTER_SDC_FLAG );
     266  m_cInterSDCResidualSCModel.initBuffer   ( eSliceType, iQp, (UChar*)INIT_INTER_SDC_RESIDUAL );
     267  m_cInterSDCResidualSignFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_INTER_SDC_SIGN_FLAG );
    253268#endif
    254269  m_pcTDecBinIf->start();
     
    22372252#endif
    22382253
     2254#if LGE_INTER_SDC_E0156
     2255Void TDecSbac::parseInterSDCFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
     2256{
     2257  UInt uiSymbol = 0;
     2258  UInt uiCtxInterSDCFlag = pcCU->getCtxInterSDCFlag( uiAbsPartIdx );
     2259
     2260  m_pcTDecBinIf->decodeBin( uiSymbol, m_cInterSDCFlagSCModel.get( 0, 0, uiCtxInterSDCFlag ) );
     2261
     2262  if( uiSymbol )
     2263  {
     2264    pcCU->setInterSDCFlagSubParts( true, uiAbsPartIdx, 0, uiDepth );
     2265    pcCU->setTrIdxSubParts( 0, uiAbsPartIdx, uiDepth );
     2266    pcCU->setCbfSubParts( 1, 1, 1, uiAbsPartIdx, uiDepth );
     2267  }
     2268  else
     2269  {
     2270    pcCU->setInterSDCFlagSubParts( false, uiAbsPartIdx, 0, uiDepth);
     2271  }
     2272}
     2273
     2274Void TDecSbac::parseInterSDCResidualData ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiSegment )
     2275{
     2276  UInt uiAbsIdx   = 0;
     2277  UInt uiSign     = 0;
     2278  Int  iIdx       = 0;
     2279
     2280  xReadExGolombLevel( uiAbsIdx, m_cInterSDCResidualSCModel.get( 0, 0, 0 ) );
     2281
     2282  uiAbsIdx++;
     2283  m_pcTDecBinIf->decodeBin( uiSign, m_cInterSDCResidualSignFlagSCModel.get( 0, 0, 0 ) );
     2284  iIdx = (Int)( uiSign ? -1 : 1 ) * uiAbsIdx;
     2285
     2286  pcCU->setInterSDCSegmentDCOffset( iIdx, uiSegment, uiAbsPartIdx );
     2287}
     2288#endif
     2289
    22392290//! \}
Note: See TracChangeset for help on using the changeset viewer.