Changeset 826 in 3DVCSoftware for branches/HTM-9.3-dev0/source


Ignore:
Timestamp:
5 Feb 2014, 18:55:49 (11 years ago)
Author:
tech
Message:

Merged 9.3-dev2-MediaTek@812.

Location:
branches/HTM-9.3-dev0/source/Lib
Files:
12 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-9.3-dev0/source/Lib/TLibCommon/ContextTables.h

    r816 r826  
    9797
    9898#if H_3D_ARP
     99#if MTK_ARP_FLAG_CABAC_SIMP_G0061
     100#define NUM_ARPW_CTX                  3       ///< number of context models for weighting factor index used by advanced residual prediction
     101#else
    99102#define NUM_ARPW_CTX                  4       ///< number of context models for weighting factor index used by advanced residual prediction
    100103#endif
     104#endif
    101105
    102106#if H_3D_IC
     107#if MTK_IC_FLAG_CABAC_SIMP_G0061
     108#define NUM_IC_FLAG_CTX               1       ///< number of context models for illumination compensation flag
     109#else
    103110#define NUM_IC_FLAG_CTX               3       ///< number of context models for illumination compensation flag
     111#endif
    104112#endif
    105113
     
    368376
    369377#if H_3D_ARP
     378#if MTK_ARP_FLAG_CABAC_SIMP_G0061
     379static const UChar
     380INIT_ARPW[3][NUM_ARPW_CTX] =
     381{
     382    { 162, 153, 162 },
     383    { 162, 153, 162 },
     384    { 162, 153, 162 },
     385};
     386#else
    370387static const UChar
    371388INIT_ARPW[3][NUM_ARPW_CTX] =
     
    376393};
    377394#endif
    378 
     395#endif
    379396#if H_3D_IC
     397#if MTK_IC_FLAG_CABAC_SIMP_G0061
     398static const UChar
     399INIT_IC_FLAG[3][NUM_IC_FLAG_CTX] = 
     400{
     401    { 154 },
     402    { 154 },
     403    { 154 },
     404};
     405#else
    380406static const UChar
    381407INIT_IC_FLAG[3][NUM_IC_FLAG_CTX] = 
     
    386412};
    387413#endif
     414#endif
    388415#if H_3D_DIM
    389416static const UChar
  • branches/HTM-9.3-dev0/source/Lib/TLibCommon/TComDataCU.cpp

    r821 r826  
    23982398  uiCtx    = ( pcTempCU ) ? ((pcTempCU->getARPW( uiTempPartIdx )==0)?0:1) : 0;
    23992399 
     2400#if !MTK_ARP_FLAG_CABAC_SIMP_G0061       
    24002401  pcTempCU = getPUAbove( uiTempPartIdx, m_uiAbsIdxInLCU + uiAbsPartIdx );
    24012402  uiCtx   += ( pcTempCU ) ? ((pcTempCU->getARPW( uiTempPartIdx )==0)?0:1): 0;
    2402  
     2403#endif
    24032404  return uiCtx;
    24042405}
    24052406#endif
    2406 
     2407#if !MTK_IC_FLAG_CABAC_SIMP_G0061
    24072408#if H_3D_IC
    24082409UInt TComDataCU::getCtxICFlag( UInt uiAbsPartIdx )
     
    24222423}
    24232424#endif
    2424 
     2425#endif
    24252426#if H_3D_DBBP
    24262427Pel* TComDataCU::getVirtualDepthBlock(UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, UInt& uiDepthStride)
     
    34603461  Bool* abCandIsInter, TComMvField* pcMvFieldNeighbours, UChar* puhInterDirNeighbours, Int* vspFlag, Int& iCount3DV, InheritedVSPDisInfo*  inheritedVSPDisInfo  )
    34613462  {
     3463#if MTK_NBDV_IVREF_FIX_G0067
     3464  if ( m_pcSlice->getViewIndex() == 0 || !m_pcSlice->getVPS()->getViewSynthesisPredFlag( m_pcSlice->getLayerIdInVps() ) || m_pcSlice->getIsDepth() || pDInfo->m_aVIdxCan == -1)
     3465#else
    34623466  if ( m_pcSlice->getViewIndex() == 0 || !m_pcSlice->getVPS()->getViewSynthesisPredFlag( m_pcSlice->getLayerIdInVps() ) || m_pcSlice->getIsDepth() )
     3467#endif
    34633468  {
    34643469    return false;
     
    46944699  Bool ivMvPredFlag   = getSlice()->getVPS()->getIvMvPredFlag( getSlice()->getLayerIdInVps() );
    46954700
     4701#if MTK_NBDV_IVREF_FIX_G0067
     4702  if ( ivMvPredFlag && cDisInfo.m_aVIdxCan!=-1)
     4703#else
    46964704  if ( ivMvPredFlag )
     4705#endif
    46974706  {
    46984707    getInterViewMergeCands(uiPUIdx, ivCandRefIdx, ivCandMv, &cDisInfo, ivCandDir , bIsDepth, pcMvFieldSP, puhInterDirSP );
     
    69506959  // Init disparity struct for results
    69516960  pDInfo->bDV = false;   
     6961#if MTK_NBDV_IVREF_FIX_G0067
     6962  pDInfo->m_aVIdxCan = -1;
     6963#endif
    69526964  // Init struct for disparities from MCP neighboring blocks
    69536965  IDVInfo cIDVInfo;
  • branches/HTM-9.3-dev0/source/Lib/TLibCommon/TComDataCU.h

    r816 r826  
    781781  UInt          getCTXARPWFlag                  ( UInt   uiAbsPartIdx                                 );
    782782#endif 
     783#if !MTK_IC_FLAG_CABAC_SIMP_G0061
    783784#if H_3D_IC
    784785  UInt          getCtxICFlag                    ( UInt   uiAbsPartIdx                                 );
     786#endif
    785787#endif
    786788  UInt          getSliceStartCU         ( UInt pos )                  { return m_sliceStartCU[pos-m_uiAbsIdxInLCU];                                                                                          }
  • branches/HTM-9.3-dev0/source/Lib/TLibCommon/TComSlice.cpp

    r816 r826  
    31323132    for ( Int refListIdx = 0; refListIdx < ((m_eSliceType==B_SLICE) ? 2 : 1); refListIdx++ )
    31333133    {
     3134#if MTK_ARP_REF_SELECTION_G0053
     3135      Int diffPOC=MAX_INT;
     3136      Int idx=-1;
     3137#endif
    31343138      for(Int i = 0; i < getNumRefIdx(RefPicList(refListIdx)); i++ )
    31353139      {
    31363140        if ( getRefPic(RefPicList(refListIdx), i)->getPOC() != getPOC() )
    31373141        {
     3142#if MTK_ARP_REF_SELECTION_G0053
     3143          if( abs(getRefPic(RefPicList(refListIdx), i)->getPOC() - getPOC()) < diffPOC)
     3144          {
     3145            diffPOC=abs(getRefPic(RefPicList(refListIdx), i)->getPOC() - getPOC());
     3146            idx=i;
     3147          }
     3148#else
    31383149          setFirstTRefIdx (RefPicList(refListIdx), i);
    31393150          break;
     3151#endif
    31403152        }
     3153#if MTK_ARP_REF_SELECTION_G0053
     3154        if(idx>=0)
     3155        {
     3156          setFirstTRefIdx (RefPicList(refListIdx), idx);
     3157        }
     3158#endif
    31413159      }
    31423160    }
  • branches/HTM-9.3-dev0/source/Lib/TLibCommon/TypeDef.h

    r816 r826  
    7878                                              // HHI_QTLPC_RAU_OFF_C0160     // JCT3V-C0160 change 2: quadtree limitation and predictive coding switched off in random access units
    7979
     80#ifdef H_3D_QTLPC
     81#define MTK_TEX_DEP_PAR_G0055             1   // Texture-partition-dependent depth partition. JCT3V-G0055
     82#endif
    8083#define H_3D_VSO                          1   // VSO, View synthesis optimization, includes:
    8184                                              // HHI_VSO
     
    102105                                              // SHARP_ARP_REF_CHECK_F0105        ARP reference picture selection and DPB check
    103106                                              // LGE_ARP_CTX_F0161                JCT3V-F0161
     107#define MTK_ARP_REF_SELECTION_G0053       1   // ARP Reference picture selection in JCT3V-G0053
     108#define MTK_ARP_FLAG_CABAC_SIMP_G0061     1   // Use 2 context for ARP flag referring to only left neighbor block in JCT3V-G0061
    104109#define H_3D_IC                           1   // Illumination Compensation, JCT3V-B0045, JCT3V-C0046, JCT3V-D0060
    105110                                              // Unifying rounding offset, for IC part, JCT3V-D0135
     
    109114                                              // LGE_IC_CTX_F0160 //JCT3V-F0160
    110115                                              // SEC_ONLY_TEXTURE_IC_F0151
     116#define MTK_IC_FLAG_CABAC_SIMP_G0061      1   // Use only 1 context for IC flag in JCT3V-G0061
    111117
    112118#if H_3D_NBDV
     
    117123                                              // NBDV_DEFAULT_VIEWIDX_BUGFIX Bug fix for invalid default view index for NBDV
    118124                                              // NTT_DoNBDV_VECTOR_CLIP_E0141 disparity vector clipping in DoNBDV, JCT3V-E0141 and JCT3V-E0209
     125#define MTK_NBDV_IVREF_FIX_G0067          1   // Disable IvMC, VSP when IVREF is not available, JCT3V-G0067
    119126#endif
    120127
     
    231238#define H_3D_ARP_WFNR                     3
    232239#endif
     240#define KHU_SIMP_SPIVMP_G0147             1  // Simplification on Sub-PU level temporal interview motion prediction
    233241
    234242#if H_3D_SPIVMP
     
    237245#define QC_DEPTH_MERGE_SIMP_G0127         1 // Remove DV candidate and shifting candidate for depth coding
    238246
    239 #define KHU_SIMP_SPIVMP_G0147             1  // Simplification on Sub-PU level temporal interview motion prediction
     247#define SEC_IC_ARP_SIG_G0072              1   // Disabling IC when ARP is enabled, option 1 in JCT3V-G0072, part 2 in JCT3V-G0121
    240248
    241249///// ***** DEPTH INTRA MODES *********
  • branches/HTM-9.3-dev0/source/Lib/TLibDecoder/TDecCu.cpp

    r820 r826  
    415415    UInt uiMergeIndex = pcCU->getMergeIndex(uiAbsPartIdx);
    416416
     417#if !SEC_IC_ARP_SIG_G0072
    417418#if H_3D_IC
    418419    m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
    419420#endif
     421#endif
    420422#if H_3D_ARP
    421423    m_pcEntropyDecoder->decodeARPW( pcCU , uiAbsPartIdx , uiDepth );
     424#endif
     425#if SEC_IC_ARP_SIG_G0072
     426#if H_3D_IC
     427    m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
     428#endif
    422429#endif
    423430
  • branches/HTM-9.3-dev0/source/Lib/TLibDecoder/TDecEntropy.cpp

    r820 r826  
    111111  pcCU->setICFlagSubParts( false , uiAbsPartIdx, 0, uiDepth );
    112112
     113#if SEC_IC_ARP_SIG_G0072
     114  if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) || pcCU->getSlice()->getIsDepth() || pcCU->getARPW( uiAbsPartIdx ) > 0 )
     115#else
    113116  if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) || pcCU->getSlice()->getIsDepth() )
     117#endif
    114118  {
    115119    return;
     
    268272      decodeMergeIndex( pcCU, uiPartIdx, uiSubPartIdx, uiDepth );
    269273      UInt uiMergeIndex = pcCU->getMergeIndex(uiSubPartIdx);
     274#if !SEC_IC_ARP_SIG_G0072
    270275#if H_3D_IC
    271276      decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
    272277#endif
     278#endif
    273279#if H_3D_ARP
    274280      decodeARPW  ( pcCU, uiAbsPartIdx, uiDepth );
     281#endif
     282#if SEC_IC_ARP_SIG_G0072
     283#if H_3D_IC
     284      decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
     285#endif
    275286#endif
    276287#if H_3D_DBBP
     
    429440        }
    430441      }
     442#if !SEC_IC_ARP_SIG_G0072
    431443#if H_3D_IC
    432444      decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
    433445#endif
     446#endif
    434447#if H_3D_ARP
    435448      decodeARPW  ( pcCU, uiAbsPartIdx, uiDepth );
     449#endif
     450#if SEC_IC_ARP_SIG_G0072
     451#if H_3D_IC
     452      decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
     453#endif
    436454#endif
    437455    }
  • branches/HTM-9.3-dev0/source/Lib/TLibDecoder/TDecSbac.cpp

    r820 r826  
    793793  Bool rapPic     = (pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR_W_RADL || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR_N_LP || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA);
    794794
     795#if MTK_TEX_DEP_PAR_G0055
     796  Bool depthDependent = false;
     797  UInt uiTexturePart = uiMode;
     798#endif
    795799  if(bDepthMapDetect && !bIntraSliceDetect && !rapPic && sps->getUseQTL() && sps->getUsePC())
    796800  {
    797801    TComDataCU *pcTextureCU = pcTexture->getCU(pcCU->getAddr());
    798802    assert(pcTextureCU->getDepth(uiAbsPartIdx) >= uiDepth);
     803#if !MTK_TEX_DEP_PAR_G0055
    799804    if (pcTextureCU->getDepth(uiAbsPartIdx) == uiDepth && pcTextureCU->getPartitionSize( uiAbsPartIdx ) != SIZE_NxN)
     805#else
     806    if(pcTextureCU->getDepth(uiAbsPartIdx) == uiDepth )
     807    {
     808      depthDependent = true;
     809      uiTexturePart = pcTextureCU->getPartitionSize( uiAbsPartIdx );
     810    }
     811    if (pcTextureCU->getDepth(uiAbsPartIdx) == uiDepth && pcTextureCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N)
     812#endif
    800813    {
    801814      bParsePartSize = false;
     
    842855    if(bParsePartSize)
    843856    {
     857#endif
     858#if MTK_TEX_DEP_PAR_G0055
     859      if (depthDependent==false || uiTexturePart == SIZE_NxN|| uiTexturePart == SIZE_2Nx2N)
     860      {
    844861#endif
    845862      UInt uiMaxNumBits = 2;
     
    879896        }
    880897      }
     898#if MTK_TEX_DEP_PAR_G0055
     899      }
     900      else if(uiTexturePart == SIZE_2NxN || uiTexturePart == SIZE_2NxnU || uiTexturePart == SIZE_2NxnD)
     901      {
     902        UInt uiMaxNumBits = 1;
     903        if ( pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth ) )
     904        {
     905          uiMaxNumBits ++;
     906        }
     907        for ( UInt ui = 0; ui < uiMaxNumBits; ui++ )
     908        {
     909          m_pcTDecBinIf->decodeBin( uiSymbol, m_cCUPartSizeSCModel.get( 0, 0, ui) );
     910          if ( uiSymbol )
     911          {
     912            break;
     913          }
     914          uiMode++;
     915        }
     916        eMode = (PartSize) uiMode;
     917        if(uiMode && pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth ) && uiSymbol==1 )
     918        {
     919          eMode = SIZE_2NxN;
     920        }
     921        else if (uiMode && pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth )==0  && uiSymbol==0)
     922        {
     923          eMode = SIZE_2NxN;
     924        }
     925        else if (uiMode && pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth ) && uiSymbol==0)
     926        {
     927          m_pcTDecBinIf->decodeBinEP(uiSymbol);
     928          eMode = (uiSymbol == 0? SIZE_2NxnU : SIZE_2NxnD);
     929        }
     930      }
     931      else if(uiTexturePart == SIZE_Nx2N|| uiTexturePart==SIZE_nLx2N || uiTexturePart==SIZE_nRx2N)
     932      {
     933        UInt uiMaxNumBits = 1;
     934        if ( pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth ) )
     935        {
     936          uiMaxNumBits ++;
     937        }
     938        for ( UInt ui = 0; ui < uiMaxNumBits; ui++ )
     939        {
     940          m_pcTDecBinIf->decodeBin( uiSymbol, m_cCUPartSizeSCModel.get( 0, 0, ui) );
     941          if ( uiSymbol )
     942          {
     943            break;
     944          }
     945          uiMode++;
     946        }
     947        eMode = (PartSize) uiMode;
     948        if(uiMode && pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth ) && uiSymbol==1 )
     949        {
     950          eMode = SIZE_Nx2N;
     951        }
     952        else if (uiMode && pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth )==0  && uiSymbol==0)
     953        {
     954          eMode = SIZE_Nx2N;
     955        }
     956        else if (uiMode && pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth ) && uiSymbol==0)
     957        {
     958          m_pcTDecBinIf->decodeBinEP(uiSymbol);
     959          eMode = (uiSymbol == 0? SIZE_nLx2N : SIZE_nRx2N);
     960        }
     961      }
     962      else
     963        assert(0);
     964#endif
    881965#if H_MV_ENC_DEC_TRAC         
    882966      DTRACE_CU("part_mode", eMode )
     
    20672151  if( 1 == uiW )   
    20682152  {
     2153#if MTK_ARP_FLAG_CABAC_SIMP_G0061
     2154    m_pcTDecBinIf->decodeBin( uiCode , m_cCUPUARPWSCModel.get( 0, 0, 2 ) );
     2155#else
    20692156    m_pcTDecBinIf->decodeBin( uiCode , m_cCUPUARPWSCModel.get( 0, 0, 3 ) );
     2157#endif
    20702158    uiW += ( 1 == uiCode ? 1 : 0 );
    20712159  }
     
    20872175{
    20882176  UInt uiSymbol = 0;
     2177#if MTK_IC_FLAG_CABAC_SIMP_G0061
     2178  m_pcTDecBinIf->decodeBin( uiSymbol, m_cCUICFlagSCModel.get( 0, 0, 0 ) );
     2179#else
    20892180  UInt uiCtxIC = pcCU->getCtxICFlag( uiAbsPartIdx );
    20902181  m_pcTDecBinIf->decodeBin( uiSymbol, m_cCUICFlagSCModel.get( 0, 0, uiCtxIC ) );
     2182#endif
    20912183#if !H_MV_ENC_DEC_TRAC
    20922184  DTRACE_CABAC_VL( g_nSymbolCounter++ );
  • branches/HTM-9.3-dev0/source/Lib/TLibEncoder/TEncCu.cpp

    r821 r826  
    563563          bTryNx2N  = false;
    564564          bTry2NxN  = false;
     565#if MTK_TEX_DEP_PAR_G0055
     566          if( pcTextureCU->getDepth(uiCUIdx) == uiDepth && pcTextureCU->getPartitionSize(uiCUIdx) != SIZE_2Nx2N)
     567          {
     568            if(pcTextureCU->getPartitionSize(uiCUIdx)==SIZE_2NxN || pcTextureCU->getPartitionSize(uiCUIdx)==SIZE_2NxnU|| pcTextureCU->getPartitionSize(uiCUIdx)==SIZE_2NxnD)
     569              bTry2NxN  = true;
     570            else
     571              bTryNx2N  = true;
     572          }
     573#endif
    565574        }
    566575      }
     
    16111620#endif
    16121621    m_pcEntropyCoder->encodeMergeIndex( pcCU, uiAbsPartIdx );
     1622#if !SEC_IC_ARP_SIG_G0072
    16131623#if H_3D_IC
    16141624    m_pcEntropyCoder->encodeICFlag  ( pcCU, uiAbsPartIdx );
    16151625#endif
     1626#endif
    16161627#if H_3D_ARP
    16171628    m_pcEntropyCoder->encodeARPW( pcCU , uiAbsPartIdx );
     1629#endif
     1630#if SEC_IC_ARP_SIG_G0072
     1631#if H_3D_IC
     1632    m_pcEntropyCoder->encodeICFlag  ( pcCU, uiAbsPartIdx );
     1633#endif
    16181634#endif
    16191635    finishCU(pcCU,uiAbsPartIdx,uiDepth);
     
    16381654  // prediction Info ( Intra : direction mode, Inter : Mv, reference idx )
    16391655  m_pcEntropyCoder->encodePredInfo( pcCU, uiAbsPartIdx );
     1656#if !SEC_IC_ARP_SIG_G0072
    16401657#if H_3D_IC
    16411658  m_pcEntropyCoder->encodeICFlag  ( pcCU, uiAbsPartIdx );
    16421659#endif
     1660#endif
    16431661#if H_3D_ARP
    16441662  m_pcEntropyCoder->encodeARPW( pcCU , uiAbsPartIdx );
     1663#endif
     1664#if SEC_IC_ARP_SIG_G0072
     1665#if H_3D_IC
     1666  m_pcEntropyCoder->encodeICFlag  ( pcCU, uiAbsPartIdx );
     1667#endif
    16451668#endif
    16461669#if H_3D_INTER_SDC
     
    18721895#if H_3D_ARP
    18731896  Int nARPWMax = rpcTempCU->getSlice()->getARPStepNum() - 1;
     1897#if SEC_IC_ARP_SIG_G0072
     1898  if( nARPWMax < 0 || !rpcTempCU->getDvInfo(0).bDV || bICFlag )
     1899#else
    18741900  if( nARPWMax < 0 || !rpcTempCU->getDvInfo(0).bDV )
     1901#endif
    18751902  {
    18761903    nARPWMax = 0;
     
    21772204  Int nARPWMax    = rpcTempCU->getSlice()->getARPStepNum() - 1;
    21782205
     2206#if SEC_IC_ARP_SIG_G0072
     2207  if( nARPWMax < 0 || ePartSize != SIZE_2Nx2N || !rpcTempCU->getDvInfo(0).bDV || rpcTempCU->getICFlag(0) )
     2208#else
    21792209  if( nARPWMax < 0 || ePartSize != SIZE_2Nx2N || !rpcTempCU->getDvInfo(0).bDV  )
     2210#endif
    21802211  {
    21812212    nARPWMax = 0;
  • branches/HTM-9.3-dev0/source/Lib/TLibEncoder/TEncEntropy.cpp

    r820 r826  
    160160Void TEncEntropy::encodeICFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD )
    161161{
     162#if SEC_IC_ARP_SIG_G0072
     163  if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) || pcCU->getSlice()->getIsDepth() || pcCU->getARPW( uiAbsPartIdx ) > 0 )
     164#else
    162165  if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) || pcCU->getSlice()->getIsDepth() )
     166#endif
    163167  {
    164168    return;
  • branches/HTM-9.3-dev0/source/Lib/TLibEncoder/TEncSbac.cpp

    r820 r826  
    691691  Bool rapPic     = (pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR_W_RADL || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR_N_LP || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA);
    692692
     693#if MTK_TEX_DEP_PAR_G0055
     694  Bool depthDependent = false;
     695  UInt uiTexturePart = eSize;
     696#endif
    693697  if(bDepthMapDetect && !bIntraSliceDetect && !rapPic && pcCU->getPic()->getReduceBitsFlag() && sps->getUseQTL() && sps->getUsePC() )
    694698  {
     
    696700    UInt uiCUIdx            = (pcCU->getZorderIdxInCU() == 0) ? uiAbsPartIdx : pcCU->getZorderIdxInCU();
    697701    assert(pcTextureCU->getDepth(uiCUIdx) >= uiDepth);
     702#if !MTK_TEX_DEP_PAR_G0055
    698703    if (pcTextureCU->getDepth(uiCUIdx) == uiDepth && pcTextureCU->getPartitionSize( uiCUIdx ) != SIZE_NxN)
     704#else
     705    if(pcTextureCU->getDepth(uiCUIdx) == uiDepth )
     706    {
     707      depthDependent = true;
     708      uiTexturePart = pcTextureCU->getPartitionSize( uiCUIdx );
     709    }
     710    if (pcTextureCU->getDepth(uiCUIdx) == uiDepth && pcTextureCU->getPartitionSize( uiCUIdx ) == SIZE_2Nx2N)
     711#endif
    699712    {
    700713      assert( eSize == SIZE_2Nx2N );
     
    718731  DTRACE_CU("part_mode", eSize )
    719732#endif       
     733#if MTK_TEX_DEP_PAR_G0055
     734    if (depthDependent==false || uiTexturePart == SIZE_NxN|| uiTexturePart == SIZE_2Nx2N)
     735    {
     736#endif
    720737  switch(eSize)
    721738  {
     
    784801    }
    785802  }
     803#if MTK_TEX_DEP_PAR_G0055
     804    }
     805    else if(uiTexturePart == SIZE_2NxN || uiTexturePart == SIZE_2NxnU || uiTexturePart == SIZE_2NxnD)
     806    {
     807      //assert(eSize!=SIZE_NxN);
     808      //assert(eSize!=SIZE_Nx2N);
     809      //assert(eSize==SIZE_2Nx2N || eSize==SIZE_2NxN || eSize==SIZE_2NxnU || eSize==SIZE_2NxnD);
     810      switch(eSize)
     811      {
     812      case SIZE_2Nx2N:
     813        {
     814          m_pcBinIf->encodeBin( 1, m_cCUPartSizeSCModel.get( 0, 0, 0) );
     815          break;
     816        }
     817      case SIZE_2NxN:
     818        {
     819          m_pcBinIf->encodeBin( 0, m_cCUPartSizeSCModel.get( 0, 0, 0) );
     820          if ( pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth ) )
     821          {     
     822            m_pcBinIf->encodeBin( 1, m_cCUPartSizeSCModel.get( 0, 0, 1) );
     823          }
     824          break;
     825        }
     826      case SIZE_2NxnU:
     827      case SIZE_2NxnD:
     828        {
     829          m_pcBinIf->encodeBin( 0, m_cCUPartSizeSCModel.get( 0, 0, 0) );
     830          m_pcBinIf->encodeBin( 0, m_cCUPartSizeSCModel.get( 0, 0, 1) );
     831          m_pcBinIf->encodeBinEP((eSize == SIZE_2NxnU? 0: 1));
     832          break;
     833        }
     834      default:
     835        {
     836          assert(0);
     837        }
     838      }
     839    }
     840    else if(uiTexturePart == SIZE_Nx2N|| uiTexturePart==SIZE_nLx2N || uiTexturePart==SIZE_nRx2N)
     841    {
     842      //assert(eSize!=SIZE_NxN);
     843      //assert(eSize!=SIZE_2NxN);
     844      //assert(eSize==SIZE_2Nx2N ||eSize==SIZE_Nx2N || eSize==SIZE_nLx2N || eSize==SIZE_nRx2N);
     845      switch(eSize)
     846      {
     847      case SIZE_2Nx2N:
     848        {
     849          m_pcBinIf->encodeBin( 1, m_cCUPartSizeSCModel.get( 0, 0, 0) );
     850          break;
     851        }
     852      case SIZE_Nx2N:
     853        {
     854          m_pcBinIf->encodeBin( 0, m_cCUPartSizeSCModel.get( 0, 0, 0) );
     855          if ( pcCU->getSlice()->getSPS()->getAMPAcc( uiDepth ) )
     856          {     
     857            m_pcBinIf->encodeBin( 1, m_cCUPartSizeSCModel.get( 0, 0, 1) );
     858          }
     859          break;
     860        }
     861      case SIZE_nLx2N:
     862      case SIZE_nRx2N:
     863        {
     864          m_pcBinIf->encodeBin( 0, m_cCUPartSizeSCModel.get( 0, 0, 0) );
     865          m_pcBinIf->encodeBin( 0, m_cCUPartSizeSCModel.get( 0, 0, 1) );
     866          m_pcBinIf->encodeBinEP((eSize == SIZE_nLx2N? 0: 1));
     867          break;
     868        }
     869      default:
     870        {
     871          assert(0);
     872        }
     873      }
     874    }
     875    else
     876    {
     877      printf("uiTexturePart=%d",uiTexturePart);
     878      assert(0);
     879    }
     880#endif
    786881}
    787882
     
    9181013  if( nBinNum > 1 )
    9191014  {
     1015#if MTK_ARP_FLAG_CABAC_SIMP_G0061
     1016     m_pcBinIf->encodeBin( ( iW == iMaxW ) ? 1 : 0, m_cCUPUARPWSCModel.get( 0, 0, 2 ) );
     1017#else
    9201018     m_pcBinIf->encodeBin( ( iW == iMaxW ) ? 1 : 0, m_cCUPUARPWSCModel.get( 0, 0, 3 ) );
     1019#endif
    9211020  }
    9221021#if H_MV_ENC_DEC_TRAC
     
    9361035  // get context function is here
    9371036  UInt uiSymbol = pcCU->getICFlag( uiAbsPartIdx ) ? 1 : 0;
     1037#if MTK_IC_FLAG_CABAC_SIMP_G0061
     1038  m_pcBinIf->encodeBin( uiSymbol, m_cCUICFlagSCModel.get( 0, 0, 0 ) );
     1039#else
    9381040  UInt uiCtxIC  = pcCU->getCtxICFlag( uiAbsPartIdx ) ;
    9391041  m_pcBinIf->encodeBin( uiSymbol, m_cCUICFlagSCModel.get( 0, 0, uiCtxIC ) );
     1042#endif
    9401043#if !H_MV_ENC_DEC_TRAC
    9411044  DTRACE_CABAC_VL( g_nSymbolCounter++ );
  • branches/HTM-9.3-dev0/source/Lib/TLibEncoder/TEncSearch.cpp

    r820 r826  
    54565456    m_pcEntropyCoder->encodeSkipFlag(pcCU, 0, true);
    54575457    m_pcEntropyCoder->encodeMergeIndex( pcCU, 0, true );
     5458#if !SEC_IC_ARP_SIG_G0072
    54585459#if H_3D_IC
    54595460    m_pcEntropyCoder->encodeICFlag( pcCU, 0, true );
    54605461#endif
     5462#endif
    54615463#if H_3D_ARP
    54625464    m_pcEntropyCoder->encodeARPW( pcCU, 0 );
     5465#endif
     5466#if SEC_IC_ARP_SIG_G0072
     5467#if H_3D_IC
     5468    m_pcEntropyCoder->encodeICFlag( pcCU, 0, true );
     5469#endif
    54635470#endif
    54645471    uiBits = m_pcEntropyCoder->getNumberOfWrittenBits();
     
    70367043    m_pcEntropyCoder->encodeSkipFlag(pcCU, 0, true);
    70377044    m_pcEntropyCoder->encodeMergeIndex(pcCU, 0, true);
     7045#if !SEC_IC_ARP_SIG_G0072
    70387046#if H_3D_IC
    70397047    m_pcEntropyCoder->encodeICFlag( pcCU, 0, true );
    70407048#endif
     7049#endif
    70417050#if H_3D_ARP
    70427051    m_pcEntropyCoder->encodeARPW( pcCU, 0 );
     7052#endif
     7053#if SEC_IC_ARP_SIG_G0072
     7054#if H_3D_IC
     7055    m_pcEntropyCoder->encodeICFlag( pcCU, 0, true );
     7056#endif
    70437057#endif
    70447058    ruiBits += m_pcEntropyCoder->getNumberOfWrittenBits();
     
    70557069    m_pcEntropyCoder->encodePartSize( pcCU, 0, pcCU->getDepth(0), true );
    70567070    m_pcEntropyCoder->encodePredInfo( pcCU, 0, true );
     7071#if !SEC_IC_ARP_SIG_G0072
    70577072#if H_3D_IC
    70587073    m_pcEntropyCoder->encodeICFlag( pcCU, 0, true );
    70597074#endif
     7075#endif
    70607076#if H_3D_ARP
    70617077    m_pcEntropyCoder->encodeARPW( pcCU , 0 );
     7078#endif
     7079#if SEC_IC_ARP_SIG_G0072
     7080#if H_3D_IC
     7081    m_pcEntropyCoder->encodeICFlag( pcCU, 0, true );
     7082#endif
    70627083#endif
    70637084#if H_3D_INTER_SDC
Note: See TracChangeset for help on using the changeset viewer.