Ignore:
Timestamp:
15 Jul 2015, 14:57:32 (9 years ago)
Author:
tech
Message:

Merged 14.1-update-dev2@1277.

Location:
branches/HTM-14.1-update-dev1
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-14.1-update-dev1

  • branches/HTM-14.1-update-dev1/source/Lib/TLibCommon/TComDataCU.h

    r1258 r1279  
    5050#include "TComPattern.h"
    5151
    52 #if H_3D_ARP
    53 #include "TComYuv.h"
    54 #endif
    5552#if H_3D
    5653#include <algorithm>
     
    6562static const UInt NUM_MOST_PROBABLE_MODES=3;
    6663
    67 #if H_3D_DBBP
     64#if NH_3D_DBBP
    6865typedef struct _DBBPTmpData
    6966{
     
    167164  Char*         m_apiMVPNum[NUM_REF_PIC_LIST_01];       ///< array of number of possible motion vectors predictors
    168165  Bool*         m_pbIPCMFlag;         ///< array of intra_pcm flags
    169 #if H_3D_NBDV
     166#if NH_3D_NBDV
    170167  DisInfo*      m_pDvInfo;
    171168#endif
    172 #if H_3D_VSP
     169#if NH_3D_VSP
    173170  Char*         m_piVSPFlag;          ///< array of VSP flags to indicate whehter a block uses VSP or not  ///< 0: non-VSP; 1: VSP
    174171#endif
    175 #if H_3D_SPIVMP
     172#if NH_3D_SPIVMP
    176173  Bool*         m_pbSPIVMPFlag;       ///< array of sub-PU IVMP flags to indicate whehter a block uses sub-PU IVMP ///< 0: non-SPIVMP; 1: SPIVMP
    177174#endif
    178 #if H_3D_ARP
     175#if NH_3D_ARP
    179176  UChar*        m_puhARPW;
    180177#endif
    181 #if H_3D_IC
     178#if NH_3D_IC
    182179  Bool*         m_pbICFlag;           ///< array of IC flags
    183180#endif
     
    190187  Pel*          m_apSegmentDCOffset[2];
    191188#endif
    192 #if H_3D_DBBP
     189#if NH_3D_DBBP
    193190  Bool*         m_pbDBBPFlag;        ///< array of DBBP flags
    194191  DbbpTmpData   m_sDBBPTmpData;
    195192#endif
    196 #if H_3D
     193#if NH_3D_MLC
    197194  Bool          m_bAvailableFlagA1;    ///< A1 available flag
    198195  Bool          m_bAvailableFlagB1;    ///< B1 available flag
     
    217214  UInt          m_uiTotalBins;        ///< sum of partition bins
    218215  Char          m_codedQP;
    219 #if H_3D
    220   DisInfo       m_cDefaultDisInfo;    ///< Default disparity information for initializing
    221 #endif
    222 #if H_3D_IV_MERGE
    223   TComMotionCand  m_mergCands[MRG_IVSHIFT+1];
    224   Int           m_baseListidc;
     216#if NH_3D_MLC
     217  DisInfo         m_cDefaultDisInfo;    ///< Default disparity information for initializing
     218  TComMotionCand  m_mergCands[MRG_IVSHIFT+1];   ///< Motion candidates for merge mode
     219  Int             m_numSpatialCands;
    225220#endif
    226221
     
    232227  Bool          xAddMVPCand           ( AMVPInfo* pInfo, RefPicList eRefPicList, Int iRefIdx, UInt uiPartUnitIdx, MVP_DIR eDir );
    233228  Bool          xAddMVPCandOrder      ( AMVPInfo* pInfo, RefPicList eRefPicList, Int iRefIdx, UInt uiPartUnitIdx, MVP_DIR eDir );
    234 #if H_3D_VSP
     229#if NH_3D_VSP
    235230  Bool          xAddVspCand( Int mrgCandIdx, DisInfo* pDInfo, Int& iCount);
    236231#endif
    237 #if H_3D_IV_MERGE
     232#if NH_3D_IV_MERGE
    238233  Bool          xAddIvMRGCand( Int mrgCandIdx, Int& iCount, Int*   ivCandDir, TComMv* ivCandMv, Int* ivCandRefIdx );
    239234#endif
     
    241236  Void          deriveRightBottomIdx        ( UInt uiPartIdx, UInt& ruiPartIdxRB );
    242237  Bool          xGetColMVP( RefPicList eRefPicList, Int ctuRsAddr, Int uiPartUnitIdx, TComMv& rcMv, Int& riRefIdx
    243 #if H_3D_TMVP
     238#if NH_3D_TMVP
    244239  ,  Bool bMRG = true
    245240#endif
     
    248243
    249244  /// compute scaling factor from POC difference
    250 #if !H_3D_ARP
     245#if !NH_3D_ARP
    251246  Int           xGetDistScaleFactor   ( Int iCurrPOC, Int iCurrRefPOC, Int iColPOC, Int iColRefPOC );
    252247#endif
     
    254249  Void xDeriveCenterIdx( UInt uiPartIdx, UInt& ruiPartIdxCenter );
    255250
    256 #if H_3D_VSP
     251#if NH_3D_VSP
    257252  Void xSetMvFieldForVSP  ( TComDataCU *cu, TComPicYuv *picRefDepth, TComMv *dv, UInt partAddr, Int width, Int height, Int *shiftLUT, RefPicList refPicList, Int refIdx, Bool isDepth, Int &vspSize );
    258253#endif
     
    265260  // create / destroy / initialize / copy
    266261  // -------------------------------------------------------------------------------------------------------------------
    267 #if H_3D_ARP
     262#if NH_3D_ARP
     263  /// compute scaling factor from POC difference
    268264  Int           xGetDistScaleFactor   ( Int iCurrPOC, Int iCurrRefPOC, Int iColPOC, Int iColRefPOC );
    269265#endif
     
    279275  Void          initSubCU             ( TComDataCU* pcCU, UInt uiPartUnitIdx, UInt uiDepth, Int qp );
    280276  Void          setOutsideCUPart      ( UInt uiAbsPartIdx, UInt uiDepth );
    281 #if H_3D_NBDV
    282   Void          copyDVInfoFrom (TComDataCU* pcCU, UInt uiAbsPartIdx);
     277#if NH_3D_NBDV
     278  Void          copyDVInfoFrom        (TComDataCU* pcCU, UInt uiAbsPartIdx);
    283279#endif
    284280
    285281  Void          copySubCU             ( TComDataCU* pcCU, UInt uiPartUnitIdx );
    286282  Void          copyInterPredInfoFrom ( TComDataCU* pcCU, UInt uiAbsPartIdx, RefPicList eRefPicList
    287 #if H_3D_NBDV
     283#if NH_3D_NBDV
    288284  , Bool bNBDV = false
    289285#endif
     
    316312#endif
    317313
     314#if NH_3D_ARP
     315  Void          setSlice              ( TComSlice* pcSlice)     { m_pcSlice = pcSlice;       }
     316  Void          setPic                ( TComDataCU* pcCU  )     { m_pcPic              = pcCU->getPic(); }
     317#endif
    318318  // -------------------------------------------------------------------------------------------------------------------
    319319  // member functions for CU data
     
    326326  Void          setCUTransquantBypassSubParts( Bool flag, UInt uiAbsPartIdx, UInt uiDepth );
    327327
    328 #if H_3D_DBBP
     328#if NH_3D_DBBP
    329329  Pel*          getVirtualDepthBlock(UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, UInt& uiDepthStride);
    330330#endif
     
    350350  Void          setPredModeSubParts   ( PredMode eMode, UInt uiAbsPartIdx, UInt uiDepth );
    351351
    352 #if H_3D_DBBP
     352#if NH_3D_DBBP
    353353  Bool*         getDBBPFlag           ()                        { return m_pbDBBPFlag;               }
    354354  Bool          getDBBPFlag           ( UInt uiIdx )            { return m_pbDBBPFlag[uiIdx];        }
     
    451451  template <typename T>
    452452  Void          setSubPart            ( T bParameter, T* pbBaseCtu, UInt uiCUAddr, UInt uiCUDepth, UInt uiPUIdx );
    453 #if H_3D_VSP
     453#if H_3D_VSP || NH_3D_DBBP
    454454  template<typename T>
    455455  Void          setSubPartT           ( T uiParameter, T* puhBaseLCU, UInt uiCUAddr, UInt uiCUDepth, UInt uiPUIdx );
     
    477477  Void          setIPCMFlag           (UInt uiIdx, Bool b )     { m_pbIPCMFlag[uiIdx] = b;           }
    478478  Void          setIPCMFlagSubParts   (Bool bIpcmFlag, UInt uiAbsPartIdx, UInt uiDepth);
    479 #if H_3D_NBDV
     479#if NH_3D_NBDV
    480480  Void          setDvInfoSubParts     ( DisInfo cDvInfo, UInt uiAbsPartIdx, UInt uiDepth );
     481#if H_3D_VSP || NH_3D_DBBP
    481482  Void          setDvInfoSubParts     ( DisInfo cDvInfo, UInt uiAbsPartIdx, UInt uiPartIdx, UInt uiDepth);
     483#endif
    482484  DisInfo*      getDvInfo             ()                        { return m_pDvInfo;                 }
    483485  DisInfo       getDvInfo             (UInt uiIdx)              { return m_pDvInfo[uiIdx];          }
    484486#endif
    485 #if H_3D_NBDV
     487#if NH_3D_NBDV
    486488  Void          xDeriveRightBottomNbIdx(Int &uiLCUIdxRBNb, Int &uiPartIdxRBNb );
    487489  Bool          xCheckSpatialNBDV (TComDataCU* pcTmpCU, UInt uiIdx, DisInfo* pNbDvInfo, Bool bSearchForMvpDv, IDVInfo* paMvpDvInfo,
    488490                                   UInt uiMvpDvPos
    489 #if H_3D_NBDV_REF
     491#if NH_3D_NBDV_REF
    490492  , Bool bDepthRefine = false
    491493#endif
     
    493495  Bool          xGetColDisMV      ( Int currCandPic, RefPicList eRefPicList, Int refidx, Int uiCUAddr, Int uiPartUnitIdx, TComMv& rcMv, Int & iTargetViewIdx, Int & iStartViewIdx );
    494496  Void          getDisMvpCandNBDV ( DisInfo* pDInfo
    495 #if H_3D_NBDV_REF
     497#if NH_3D_NBDV_REF
    496498   , Bool bDepthRefine = false
    497499#endif
    498500   );
    499501   
     502#if NH_3D_IV_MERGE
     503  Void          getDispforDepth  ( UInt uiPartIdx, UInt uiPartAddr, DisInfo* cDisp);
     504#endif
     505
    500506#if H_3D
    501507  Void          getDispforDepth  ( UInt uiPartIdx, UInt uiPartAddr, DisInfo* cDisp);
    502508  Bool          getDispMvPredCan(UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDis, Int* iPdm );
    503509#endif
    504 #if H_3D_NBDV_REF
     510#if NH_3D_NBDV_REF
    505511  Pel           getMcpFromDM(TComPicYuv* pcBaseViewDepthPicYuv, TComMv* mv, Int iBlkX, Int iBlkY, Int iWidth, Int iHeight, Int* aiShiftLUT );
    506512  Void          estimateDVFromDM(Int refViewIdx, UInt uiPartIdx, TComPic* picDepth, UInt uiPartAddr, TComMv* cMvPred );
    507 #endif //H_3D_NBDV_REF
     513#endif //NH_3D_NBDV_REF
    508514#endif
    509515#if NH_3D_DIS
     
    513519  Void          getIVNStatus       ( UInt uiPartIdx,  DisInfo* pDInfo, Bool& bIVFMerge,  Int& iIVFMaxD);
    514520#endif
    515 #if H_3D_SPIVMP
     521#if NH_3D_SPIVMP
    516522  Void          getSPPara(Int iPUWidth, Int iPUHeight, Int& iNumSP, Int& iNumSPInOneLine, Int& iSPWidth, Int& iSPHeight);
    517523  Void          getSPAbsPartIdx(UInt uiBaseAbsPartIdx, Int iWidth, Int iHeight, Int iPartIdx, Int iNumPartLine, UInt& ruiPartAddr );
    518524  Void          setInterDirSP( UInt uiDir, UInt uiAbsPartIdx, Int iWidth, Int iHeight );
    519525#endif
    520 #if H_3D_IV_MERGE
     526#if NH_3D_IV_MERGE
    521527  Bool          getInterViewMergeCands          ( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* availableMcDc, Bool bIsDepth           
    522528
    523 #if H_3D_SPIVMP
     529#if NH_3D_SPIVMP
    524530    , TComMvField* pcMFieldSP, UChar* puhInterDirSP
    525531#endif   
     
    527533    );   
    528534#endif
    529 #if H_3D_ARP
     535#if NH_3D_ARP
    530536  UChar*        getARPW            ()                        { return m_puhARPW;               }
    531537  UChar         getARPW            ( UInt uiIdx )            { return m_puhARPW[uiIdx];        }
    532538  Void          setARPW            ( UInt uiIdx, UChar w )   { m_puhARPW[uiIdx] = w;           }
    533539  Void          setARPWSubParts    ( UChar w, UInt uiAbsPartIdx, UInt uiDepth );
    534   Double        getARPWFactor      ( UInt uiIdx );
    535 #endif
    536 #if H_3D_IC
     540#endif
     541#if NH_3D_IC
    537542  Bool*         getICFlag          ()                        { return m_pbICFlag;               }
    538543  Bool          getICFlag          ( UInt uiIdx )            { return m_pbICFlag[uiIdx];        }
     
    540545  Void          setICFlagSubParts  ( Bool bICFlag,  UInt uiAbsPartIdx, UInt uiPartIdx, UInt uiDepth );
    541546  Bool          isICFlagRequired   ( UInt uiAbsPartIdx );
     547  Void          getPartIndexAndSize( UInt uiPartIdx, UInt& ruiPartAddr, Int& riWidth, Int& riHeight, UInt uiAbsPartIdx = 0, Bool bLCU = false);
     548#elif NH_3D_VSP
    542549  Void          getPartIndexAndSize( UInt uiPartIdx, UInt& ruiPartAddr, Int& riWidth, Int& riHeight, UInt uiAbsPartIdx = 0, Bool bLCU = false);
    543550#else
     
    647654  Bool          hasEqualMotion              ( UInt uiAbsPartIdx, TComDataCU* pcCandCU, UInt uiCandAbsPartIdx );
    648655
    649 #if H_3D
    650   Bool          getAvailableFlagA1() { return m_bAvailableFlagA1;}
    651   Bool          getAvailableFlagB1() { return m_bAvailableFlagB1;}
    652   Bool          getAvailableFlagB0() { return m_bAvailableFlagB0;}
    653   Bool          getAvailableFlagA0() { return m_bAvailableFlagA0;}
    654   Bool          getAvailableFlagB2() { return m_bAvailableFlagB2;}
     656#if NH_3D_MLC
     657  Bool          getAvailableFlagA1() { return m_bAvailableFlagA1;   }
     658  Bool          getAvailableFlagB1() { return m_bAvailableFlagB1;   }
     659  Bool          getAvailableFlagB0() { return m_bAvailableFlagB0;   }
     660  Bool          getAvailableFlagA0() { return m_bAvailableFlagA0;   }
     661  Bool          getAvailableFlagB2() { return m_bAvailableFlagB2;   }
    655662  Void          initAvailableFlags() { m_bAvailableFlagA1 = m_bAvailableFlagB1 = m_bAvailableFlagB0 = m_bAvailableFlagA0 = m_bAvailableFlagB2 = 0;  }
    656663  Void          buildMCL(TComMvField* pcMFieldNeighbours, UChar* puhInterDirNeighbours
    657 #if H_3D_VSP
     664#if NH_3D_VSP
    658665    , Int* vspFlag
    659666#endif
    660 #if H_3D_SPIVMP
     667#if NH_3D_SPIVMP
    661668    , Bool* pbSPIVMPFlag
    662669#endif
    663670    , Int& numValidMergeCand
    664671    );
    665   Void          getInterMergeCandidates( UInt uiAbsPartIdx, UInt uiPUIdx, TComMvField* pcMvFieldNeighbours, UChar* puhInterDirNeighbours, Int& numValidMergeCand, Int mrgCandIdx = -1);
    666   Void          xGetInterMergeCandidates ( UInt uiAbsPartIdx, UInt uiPUIdx, TComMvField* pcMFieldNeighbours, UChar* puhInterDirNeighbours
    667 #else
     672  Void          xGetInterMergeCandidates      ( UInt uiAbsPartIdx, UInt uiPUIdx, TComMvField* pcMFieldNeighbours, UChar* puhInterDirNeighbours
     673#if NH_3D_SPIVMP
     674  , TComMvField* pcMvFieldSP, UChar* puhInterDirSP
     675#endif
     676  , Int& numValidMergeCand, Int mrgCandIdx = -1 );
     677#endif
    668678  Void          getInterMergeCandidates       ( UInt uiAbsPartIdx, UInt uiPUIdx, TComMvField* pcMFieldNeighbours, UChar* puhInterDirNeighbours, Int& numValidMergeCand, Int mrgCandIdx = -1 );
    669 #endif
    670 #if H_3D_SPIVMP
    671                                             , TComMvField* pcMvFieldSP, UChar* puhInterDirSP
    672 #endif
    673 
    674 #if H_3D_VSP
    675 #if H_3D_SPIVMP
     679
     680#if NH_3D_VSP
     681#if NH_3D_SPIVMP
    676682  Bool*         getSPIVMPFlag        ()                        { return m_pbSPIVMPFlag;          }
    677683  Bool          getSPIVMPFlag        ( UInt uiIdx )            { return m_pbSPIVMPFlag[uiIdx];   }
     
    698704  Bool          isBipredRestriction( UInt puIdx );
    699705
    700 #if H_3D_IC
    701   Bool          isIC      ( UInt uiPartIdx );
    702 #endif
    703 
    704706  // -------------------------------------------------------------------------------------------------------------------
    705707  // member functions for symbol prediction (most probable / mode conversion)
     
    720722  UInt          getCtxSkipFlag                  ( UInt   uiAbsPartIdx                                 );
    721723  UInt          getCtxInterDir                  ( UInt   uiAbsPartIdx                                 );
    722 #if H_3D_ARP
     724#if NH_3D_ARP
    723725  UInt          getCTXARPWFlag                  ( UInt   uiAbsPartIdx                                 );
    724726#endif 
Note: See TracChangeset for help on using the changeset viewer.