Ignore:
Timestamp:
8 Mar 2013, 16:13:08 (12 years ago)
Author:
mediatek-htm
Message:

Added FCO_FIX, FCO_FIX_SPS_CHANGE, and FCO_DVP_REFINE_C0132_C0170 macros to support FCO.
The new macros are default disabled in CTC.

Location:
branches/HTM-6.0-Mediatek/source/Lib/TLibCommon
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-6.0-Mediatek/source/Lib/TLibCommon/TComDataCU.cpp

    r296 r303  
    35963596#if H3D_IVMP
    35973597#if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137
     3598#if FCO_FIX
     3599  const Int extraMergeCand = ( ( ( getSlice()->getIsDepth() && m_pcSlice->getTexturePic() ) || getSlice()->getSPS()->getMultiviewMvPredMode() )? 1 : 0 );
     3600#else
    35983601  const Int extraMergeCand = ( ( getSlice()->getIsDepth() || getSlice()->getSPS()->getMultiviewMvPredMode() )? 1 : 0 );
     3602#endif
    35993603#else
    36003604  const Int extraMergeCand = ( getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 );
     
    36513655  if(!bNoPdmMerge)
    36523656  {
     3657#if FCO_DVP_REFINE_C0132_C0170
     3658    if( !getPic()->getDepthCoded() )
     3659#endif
    36533660    getDisMvpCandNBDV(uiPUIdx, uiAbsPartIdx, &cDisInfo , true
    36543661#if MERL_VSP_C0152
     
    36573664);
    36583665  }
     3666#if FCO_DVP_REFINE_C0132_C0170
     3667  if(getPic()->getDepthCoded() )
     3668  {
     3669    TComPic*      pcCodedDepthMap = getPic()->getRecDepthMap();
     3670    TComMv        cColMv;
     3671
     3672    cColMv.setZero();
     3673    estimateDVFromDM(uiPUIdx, pcCodedDepthMap, uiAbsPartIdx, &cColMv, false);
     3674
     3675    cDisInfo.iN = 1;
     3676    cDisInfo.m_acMvCand[0].setHor( cColMv.getHor() );
     3677    cDisInfo.m_acMvCand[0].setVer( cColMv.getVer() );
     3678    cDisInfo.m_aVIdxCan[0] = 0;
     3679
     3680  }
     3681#endif
    36593682  if(cDisInfo.iN==0)
    36603683  {
     
    36693692
    36703693#if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137
     3694#if FCO_FIX
     3695  if( m_pcSlice->getIsDepth() && m_pcSlice->getTexturePic() )
     3696#else
    36713697  if( m_pcSlice->getIsDepth())
     3698#endif
    36723699  {
    36733700    UInt uiPartIdxCenter;
     
    60796106      DisInfo cDisInfo;
    60806107      cDisInfo.iN = 0;
     6108#if FCO_DVP_REFINE_C0132_C0170
     6109      if( !getPic()->getDepthCoded() )
     6110#endif
    60816111      getDisMvpCandNBDV(uiPartIdx, uiPartAddr, &cDisInfo, false
    60826112#if MERL_VSP_C0152
     
    60846114#endif
    60856115              );
     6116#if FCO_DVP_REFINE_C0132_C0170
     6117      if(getPic()->getDepthCoded() )
     6118      {
     6119        TComPic*      pcCodedDepthMap = getPic()->getRecDepthMap();
     6120        TComMv        cColMv;
     6121
     6122        cColMv.setZero();
     6123        estimateDVFromDM(uiPartIdx, pcCodedDepthMap, uiPartAddr, &cColMv, false);
     6124
     6125        cDisInfo.iN = 1;
     6126        cDisInfo.m_acMvCand[0].setHor( cColMv.getHor() );
     6127        cDisInfo.m_acMvCand[0].setVer( cColMv.getVer() );
     6128        cDisInfo.m_aVIdxCan[0] = 0;
     6129      }
     6130#endif
    60866131      if(cDisInfo.iN==0)
    60876132      {
     
    79217966  PartSize m_peSaved =  getPartitionSize( 0 );
    79227967  m_pePartSize[0] =  SIZE_2Nx2N;
     7968#if FCO_DVP_REFINE_C0132_C0170
     7969  if(getPic()->getDepthCoded() )
     7970  {
     7971    TComPic*      pcCodedDepthMap = getPic()->getRecDepthMap();
     7972    TComMv        cColMv;
     7973
     7974    cColMv.setZero();
     7975    estimateDVFromDM(0, pcCodedDepthMap, 0, &cColMv, false);
     7976
     7977    cDisInfo.iN = 1;
     7978    cDisInfo.m_acMvCand[0].setHor( cColMv.getHor() );
     7979    cDisInfo.m_acMvCand[0].setVer( cColMv.getVer() );
     7980    cDisInfo.m_aVIdxCan[0] = 0;
     7981
     7982  }
     7983  else
     7984#endif
    79237985  getDisMvpCandNBDV( 0, 0,  &cDisInfo, false );
    79247986  if( cDisInfo.iN == 0)
  • branches/HTM-6.0-Mediatek/source/Lib/TLibCommon/TComPic.cpp

    r296 r303  
    5959#endif
    6060#endif
     61#if FCO_DVP_REFINE_C0132_C0170
     62  m_bDepthCoded       = false;
     63  m_pcRecDepthMap     = NULL;
     64#endif
    6165#if H3D_IVMP
    6266  m_pcOrgDepthMap     = NULL;
  • branches/HTM-6.0-Mediatek/source/Lib/TLibCommon/TComPic.h

    r296 r303  
    7373#endif
    7474
     75#if FCO_DVP_REFINE_C0132_C0170
     76  Bool                  m_bDepthCoded;
     77  TComPic*              m_pcRecDepthMap;   
     78#endif
     79
    7580#if LG_ZEROINTRADEPTHRESI_A0087
    7681  Int                   m_uiIntraPeriod;
     
    171176  Bool          getCandPicCheckedFlag ()                { return m_checked;}
    172177#endif
     178#endif
     179
     180#if FCO_DVP_REFINE_C0132_C0170
     181  void setRecDepthMap(TComPic * pRecPic)                { m_pcRecDepthMap = pRecPic; }
     182  TComPic * getRecDepthMap()                            { return m_pcRecDepthMap; }
     183  void setDepthCoded(Bool flag)                         { m_bDepthCoded = flag; }
     184  Bool getDepthCoded()                                  { return m_bDepthCoded; }
    173185#endif
    174186
  • branches/HTM-6.0-Mediatek/source/Lib/TLibCommon/TComPrediction.cpp

    r296 r303  
    14341434  Int dstStride = dstPic->getStride();
    14351435  Int depStride =  pPicBaseDepth->getStride();
    1436 
    14371436  Int depthPosX = Clip3(0,   widthLuma - size_x - 1,  (posX/nTxtPerDepthX) + (mv->getHor()>>2));
    14381437  Int depthPosY = Clip3(0,   heightLuma- size_y - 1,  (posY/nTxtPerDepthY) + (mv->getVer()>>2));
  • branches/HTM-6.0-Mediatek/source/Lib/TLibCommon/TComSlice.cpp

    r296 r303  
    17611761
    17621762Void
     1763#if FCO_FIX_SPS_CHANGE
     1764TComSPS::initMultiviewSPSDepth( UInt uiViewId, Int iViewOrderIdx, UInt uiCamParPrecision, Bool bCamParSlice, Int** aaiScale, Int** aaiOffset )
     1765#else
    17631766TComSPS::initMultiviewSPSDepth( UInt uiViewId, Int iViewOrderIdx )
     1767#endif
    17641768{
    17651769  AOT( uiViewId == 0 && iViewOrderIdx != 0 );
     
    17691773  m_iViewOrderIdx         = iViewOrderIdx;
    17701774  m_bDepth                = true;
     1775#if FCO_FIX_SPS_CHANGE
     1776  m_uiCamParPrecision     = ( m_uiViewId ? uiCamParPrecision : 0 );
     1777  m_bCamParInSliceHeader  = ( m_uiViewId ? bCamParSlice  : false );
     1778#else
    17711779  m_uiCamParPrecision     = 0;
    17721780  m_bCamParInSliceHeader  = false;
     1781#endif
    17731782  ::memset( m_aaiCodedScale,  0x00, sizeof( m_aaiCodedScale  ) );
    17741783  ::memset( m_aaiCodedOffset, 0x00, sizeof( m_aaiCodedOffset ) );
     1784#if FCO_FIX_SPS_CHANGE
     1785#if !QC_MVHEVC_B0046
     1786  if( !m_bCamParInSliceHeader )
     1787  {
     1788    for( UInt uiBaseViewId = 0; uiBaseViewId < m_uiViewId; uiBaseViewId++ )
     1789    {
     1790      m_aaiCodedScale [ 0 ][ uiBaseViewId ] = aaiScale [ uiBaseViewId ][   m_uiViewId ];
     1791      m_aaiCodedScale [ 1 ][ uiBaseViewId ] = aaiScale [   m_uiViewId ][ uiBaseViewId ];
     1792      m_aaiCodedOffset[ 0 ][ uiBaseViewId ] = aaiOffset[ uiBaseViewId ][   m_uiViewId ];
     1793      m_aaiCodedOffset[ 1 ][ uiBaseViewId ] = aaiOffset[   m_uiViewId ][ uiBaseViewId ];
     1794    }
     1795  }
     1796#endif
     1797#endif
     1798
    17751799}
    17761800
  • branches/HTM-6.0-Mediatek/source/Lib/TLibCommon/TComSlice.h

    r296 r303  
    623623
    624624  Void initMultiviewSPS      ( UInt uiViewId, Int iViewOrderIdx = 0, UInt uiCamParPrecision = 0, Bool bCamParSlice = false, Int** aaiScale = 0, Int** aaiOffset = 0 );
     625#if FCO_FIX_SPS_CHANGE
     626  Void initMultiviewSPSDepth ( UInt uiViewId, Int iViewOrderIdx, UInt uiCamParPrecision = 0, Bool bCamParSlice = false, Int** aaiScale = 0, Int** aaiOffset = 0 );
     627#else
    625628  Void initMultiviewSPSDepth ( UInt uiViewId, Int iViewOrderIdx );
     629#endif
    626630
    627631  UInt getViewId             ()  { return m_uiViewId; }
  • branches/HTM-6.0-Mediatek/source/Lib/TLibCommon/TypeDef.h

    r296 r303  
    171171#if FLEX_CODING_ORDER_M23723
    172172#define DISABLE_FCO_FOR_VSO               0 // Optional compile settings to disable VSO with FCO.
     173#define FCO_DVP_REFINE_C0132_C0170        0 // depth oriented disparity vector prediction from JCT3V-C0132 and JCT3V-C0170
     174#define FCO_FIX                           0 // Bug fix for C0137 and C0152 on FCO
     175#define FCO_FIX_SPS_CHANGE                0 // Sending camera parameters in SPS of depth for depth to disparity conversion used by VSP and DoDVP
     176#else
     177#define DISABLE_FCO_FOR_VSO               0 // Optional compile settings to disable VSO with FCO.
     178#define FCO_DVP_REFINE_C0132_C0170        0 // depth oriented disparity vector prediction from JCT3V-C0132 and JCT3V-C0170
     179#define FCO_FIX                           0 // Fixing bugs from HTM 6.0 which
     180#define FCO_FIX_SPS_CHANGE                0 // Fixing bugs from HTM 6.0 which
    173181#endif
    174182
Note: See TracChangeset for help on using the changeset viewer.