Ignore:
Timestamp:
22 May 2015, 05:38:04 (9 years ago)
Author:
sharpjp-htm
Message:

Migration of illumination compensation(NH_3D_IC) and small fix(H_MV_ENC_DEC_TRAC_FIX)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-14.1-update-dev2-Sharp/source/Lib/TLibCommon/TComDataCU.cpp

    r1213 r1225  
    137137  m_puhARPW              = NULL;
    138138#endif
    139 #if H_3D_IC
     139#if NH_3D_IC
    140140  m_pbICFlag             = NULL;
    141141#endif
     
    252252    m_puhARPW            = new UChar[ uiNumPartition];
    253253#endif
    254 #if H_3D_IC
     254#if NH_3D_IC
    255255    m_pbICFlag           = (Bool* )xMalloc(Bool,   uiNumPartition);
    256256#endif
     
    471471    if ( m_puhARPW            ) { delete[] m_puhARPW;           m_puhARPW           = NULL; }
    472472#endif
    473 #if H_3D_IC
     473#if NH_3D_IC
    474474    if ( m_pbICFlag           ) { xFree(m_pbICFlag);            m_pbICFlag          = NULL; }
    475475#endif
     
    601601    m_puhARPW   [ui] = pcFrom->getARPW( ui );
    602602#endif
    603 #if H_3D_IC
    604     m_pbICFlag[ui]   =  pcFrom->m_pbICFlag[ui];
     603#if NH_3D_IC
     604  memset( m_pbICFlag          , false,                      m_uiNumPartition * sizeof( *m_pbICFlag ) );
    605605#endif
    606606
     
    654654    memset( m_puhARPW           + firstElement, 0,                        numElements * sizeof( UChar )         );
    655655#endif
    656 #if H_3D_IC
    657     memset( m_pbICFlag          + firstElement, false,                    numElements * sizeof( *m_pbICFlag )   );
    658 #endif
    659 
    660656
    661657#if H_3D_DIM
     
    815811      m_puhARPW[ui] = 0;
    816812#endif
    817 #if H_3D_IC
     813#if NH_3D_IC
    818814      m_pbICFlag[ui]  = false;
    819815#endif
     
    926922  memset( m_puhHeight,         uhHeight, iSizeInUchar );
    927923  memset( m_pbIPCMFlag,        0, iSizeInBool  );
    928 #if H_3D_IC
     924#if NH_3D_IC
    929925  memset( m_pbICFlag,          0, iSizeInBool  );
    930926#endif
     
    986982      m_puhARPW           [ui] = pcCU->getARPW( uiPartOffset+ui );
    987983#endif
    988 #if H_3D_IC
     984#if NH_3D_IC
    989985      m_pbICFlag          [ui] = pcCU->m_pbICFlag[uiPartOffset+ui];
    990986#endif
     
    10931089  m_puhARPW             = pcCU->getARPW()             + uiPart;
    10941090#endif
    1095 #if H_3D_IC
     1091#if NH_3D_IC
    10961092  m_pbICFlag            = pcCU->getICFlag()           + uiPart;
    10971093#endif
     
    12591255  }
    12601256#endif
    1261 #if H_3D_IC
     1257#if NH_3D_IC
    12621258  m_pbICFlag           = pcCU->getICFlag()                + uiAbsPartIdx;
    12631259#endif
     
    13831379  memcpy( m_puhARPW             + uiOffset, pcCU->getARPW(),              iSizeInUchar );
    13841380#endif
    1385 #if H_3D_IC
     1381#if NH_3D_IC
    13861382  memcpy( m_pbICFlag            + uiOffset, pcCU->getICFlag(),            iSizeInBool );
    13871383#endif
     
    15041500  memcpy( rpcCU->getARPW()             + m_uiAbsIdxInLCU, m_puhARPW,             iSizeInUchar );
    15051501#endif
    1506 #if H_3D_IC
    1507   memcpy( rpcCU->getICFlag()           + m_uiAbsIdxInLCU, m_pbICFlag,            iSizeInBool );
     1502#if NH_3D_IC
     1503  memcpy( pCtu->getICFlag() + m_absZIdxInCtu, m_pbICFlag, sizeof( *m_pbICFlag ) * m_uiNumPartition );
    15081504#endif
    15091505
     
    15451541#if H_3D_ARP
    15461542  memcpy( rpcCU->getARPW()             + uiPartOffset, m_puhARPW,             iSizeInUchar );
    1547 #endif
    1548 #if H_3D_IC
    1549   memcpy( rpcCU->getICFlag()           + uiPartOffset, m_pbICFlag,            iSizeInBool );
    15501543#endif
    15511544
     
    27312724
    27322725// This is for use by a leaf/sub CU object only, with no additional AbsPartIdx
    2733 #if H_3D_IC
     2726#if NH_3D_IC
    27342727Void TComDataCU::getPartIndexAndSize( UInt uiPartIdx, UInt& ruiPartAddr, Int& riWidth, Int& riHeight, UInt uiAbsPartIdx, Bool bLCU)
    27352728{
     
    36993692#endif
    37003693
    3701 #if H_3D_IC
     3694#if NH_3D_IC
    37023695  Bool bICFlag = getICFlag(uiAbsPartIdx);
    37033696#endif
     
    37373730#if H_3D_VSP
    37383731    , (pcCULeft->getVSPFlag(uiLeftPartIdx) != 0
    3739 #if H_3D_IC
     3732#if NH_3D_IC
    37403733      && !bICFlag
    37413734#endif
     
    41854178    if (
    41864179      (!getAvailableFlagA1() || !(pcCULeft->getVSPFlag(uiLeftPartIdx) != 0)) &&
    4187 #if H_3D_IC
     4180#if NH_3D_IC
    41884181      !bICFlag &&
    41894182#endif
     
    52225215  return ( getSkipFlag( uiPartIdx ) );
    52235216}
    5224 
    5225 #if H_3D_IC
    5226 Bool TComDataCU::isIC( UInt uiPartIdx )
    5227 {
    5228     if ( m_pcSlice->isIntra () )
    5229     {
    5230         return false;
    5231     }
    5232     return ( ( getSkipFlag(uiPartIdx) || getPredictionMode(uiPartIdx) == MODE_INTER) && getICFlag( uiPartIdx ) && isICFlagRequired( uiPartIdx ) );
    5233 }
    5234 #endif
    52355217
    52365218// ====================================================================================================================
     
    66816663#endif
    66826664
    6683 #if H_3D_IC
     6665#if NH_3D_IC
    66846666Void TComDataCU::setICFlagSubParts( Bool bICFlag, UInt uiAbsPartIdx, UInt uiPartIdx, UInt uiDepth )
    66856667{
    6686   memset( m_pbICFlag + uiAbsPartIdx, bICFlag, (m_pcPic->getNumPartInCU() >> ( 2 * uiDepth ))*sizeof(Bool) );
     6668  memset( m_pbICFlag + uiAbsPartIdx, bICFlag, (m_pcPic->getNumPartitionsInCtu() >> ( 2 * uiDepth ))*sizeof(Bool) );
    66876669}
    66886670
Note: See TracChangeset for help on using the changeset viewer.