Ignore:
Timestamp:
26 Nov 2012, 18:35:20 (12 years ago)
Author:
qualcomm
Message:

JCT3V-B0046, MVHEVC codec;
Two bugs fixed for HTM:
1) encoder crash, see the macro 'BUG_FIX_HTM'
2) wrong place for '#endif' in TComPrediction.h

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-5.0-Qualcomm/source/App/TAppEncoder/TAppEncTop.cpp

    r189 r194  
    6767Void TAppEncTop::xInitLibCfg()
    6868{
    69 #if VIDYO_VPS_INTEGRATION
     69#if VIDYO_VPS_INTEGRATION|MVHEVC
     70#if !MVHEVC
    7071  UInt layerId = 0;
     72#endif
    7173  // TODO: fix the assumption here that the temporal structures are all equal across all layers???
    7274  m_cVPS.setMaxTLayers( m_maxTempLayer[0] );
     75#if MVHEVC
     76  m_cVPS.setMaxLayers( m_iNumberOfViews );
     77#else
    7378  m_cVPS.setMaxLayers( m_iNumberOfViews * (m_bUsingDepthMaps ? 2:1) );
     79#endif
    7480  for(Int i = 0; i < MAX_TLAYER; i++)
    7581  {
     
    101107    m_acTEncTopList[iViewIdx]->setViewId                       ( iViewIdx );
    102108    m_acTEncTopList[iViewIdx]->setIsDepth                      ( false );
     109#if MVHEVC
     110    m_acTEncTopList[iViewIdx]->setLayerId                      ( iViewIdx );
     111    m_cVPS.setViewId                                           ( m_aiVId[ iViewIdx ], iViewIdx );
     112#else
    103113    m_acTEncTopList[iViewIdx]->setViewOrderIdx                 ( m_cCameraData.getViewOrderIndex()[ iViewIdx ] );
    104114#if VIDYO_VPS_INTEGRATION
     
    117127    m_acTEncTopList[iViewIdx]->setCodedScale                   ( m_cCameraData.getCodedScale             () );
    118128    m_acTEncTopList[iViewIdx]->setCodedOffset                  ( m_cCameraData.getCodedOffset            () );
     129#endif   
    119130
    120131  //====== Coding Structure ========
     
    406417      m_acTEncDepthTopList[iViewIdx]->setViewId                       ( iViewIdx );
    407418      m_acTEncDepthTopList[iViewIdx]->setIsDepth                      ( true );
     419#if MVHEVC
     420      m_acTEncDepthTopList[iViewIdx]->setLayerId                      ( iViewIdx );
     421#else
    408422      m_acTEncDepthTopList[iViewIdx]->setViewOrderIdx                 ( m_cCameraData.getViewOrderIndex()[ iViewIdx ] );
     423#endif
    409424#if VIDYO_VPS_INTEGRATION
    410425      layerId = iViewIdx * 2 + 1;
     
    821836  {
    822837    m_acTEncTopList[iViewIdx]->init( this );
     838#if MVHEVC
     839  //set setNumDirectRefLayer
     840  Int iNumDirectRef = m_acTEncTopList[iViewIdx]->getSPS()->getNumberOfUsableInterViewRefs();
     841  m_acTEncTopList[iViewIdx]->getEncTop()->getVPS()->setNumDirectRefLayer(iNumDirectRef, iViewIdx);
     842  for(Int iNumIvRef = 0; iNumIvRef < iNumDirectRef; iNumIvRef ++)
     843  {
     844    Int iLayerId = m_acTEncTopList[iViewIdx]->getSPS()->getUsableInterViewRef(iNumIvRef);
     845    m_acTEncTopList[iViewIdx]->getEncTop()->getVPS()->setDirectRefLayerId( iLayerId + iViewIdx, iViewIdx, iNumIvRef);
     846  }
     847#endif
    823848  }
    824849  for(Int iViewIdx=0; iViewIdx<m_iNumberOfViews; iViewIdx++)
     
    862887  TComPicYuv*       pcPicYuvOrg = new TComPicYuv;
    863888  TComPicYuv*       pcDepthPicYuvOrg = new TComPicYuv;
     889#if !MVHEVC
    864890  TComPicYuv*       pcPdmDepthOrg    = new TComPicYuv;
     891#endif
    865892  TComPicYuv*       pcPicYuvRec = NULL;
    866893  TComPicYuv*       pcDepthPicYuvRec = NULL;
     
    963990    {
    964991      Int  iNumEncoded = 0;
     992#if !MVHEVC
    965993      UInt iNextPoc = m_acTEncTopList[0] -> getFrameId( gopId );
    966994      if ( iNextPoc < m_iFrameToBeEncoded )
     
    968996      m_cCameraData.update( iNextPoc );
    969997      }
     998#endif
    970999      for(Int iViewIdx=0; iViewIdx < m_iNumberOfViews; iViewIdx++ )
    9711000      {
     
    10221051  delete pcDepthPicYuvOrg;
    10231052  pcDepthPicYuvOrg = NULL;
    1024  
     1053
     1054#if !MVHEVC
     1055#if BUG_FIX_HTM
     1056  if ( pcPdmDepthOrg != NULL && m_uiMultiviewMvRegMode )
     1057#else
    10251058  if ( pcPdmDepthOrg != NULL )
     1059#endif
    10261060  {
    10271061    pcPdmDepthOrg->destroy();
     
    10291063    pcPdmDepthOrg = NULL;
    10301064  };
    1031 
     1065#endif
    10321066 
    10331067  for(Int iViewIdx=0; iViewIdx < m_iNumberOfViews; iViewIdx++ )
     
    12331267    case NAL_UNIT_CODED_SLICE:
    12341268#if H0566_TLA
     1269#if !QC_REM_IDV
    12351270    case NAL_UNIT_CODED_SLICE_IDV:
     1271#endif
    12361272    case NAL_UNIT_CODED_SLICE_TLA:
    12371273    case NAL_UNIT_CODED_SLICE_CRA:
Note: See TracChangeset for help on using the changeset viewer.