Changeset 1602 in SHVCSoftware


Ignore:
Timestamp:
12 Dec 2017, 03:02:27 (7 years ago)
Author:
seregin
Message:

keep original depth for ILRP for the motion compensation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-dev/source/Lib/TLibCommon/TComPic.cpp

    r1600 r1602  
    8787
    8888  const ChromaFormat chromaFormatIDC = sps.getChromaFormatIdc();
    89   const Int          iWidth          = sps.getPicWidthInLumaSamples();
    90   const Int          iHeight         = sps.getPicHeightInLumaSamples();
    91   const UInt         uiMaxCuWidth    = sps.getMaxCUWidth();
    92   const UInt         uiMaxCuHeight   = sps.getMaxCUHeight();
    93 #if SVC_EXTENSION
    94   UInt maxDepth = 0;
     89  const Int          iWidth = sps.getPicWidthInLumaSamples();
     90  const Int          iHeight = sps.getPicHeightInLumaSamples();
     91  const UInt         uiMaxCuWidth = sps.getMaxCUWidth();
     92  const UInt         uiMaxCuHeight = sps.getMaxCUHeight();
     93  const UInt         uiMaxDepth = sps.getMaxTotalCUDepth();
     94  const Window& conformanceWindow = sps.getConformanceWindow();
     95
     96  // original uiMaxDepth must be used for motion compensation for inter-layer prediction, since EL partition address is used to derive reference PU location.
     97  m_maxILRPdepth = uiMaxDepth;
     98
    9599  if( isILRP )
    96100  {
    97     while( ( uiMaxCuWidth >> maxDepth ) > 16 )
    98     {
    99       maxDepth++;
    100     }
    101   }
    102 
    103   const UInt         uiMaxDepth      = ( ( uiMaxCuWidth >> sps.getMaxTotalCUDepth() ) > 16 && isILRP ) ? maxDepth : sps.getMaxTotalCUDepth();
    104 
    105   if( isILRP )
    106   {
    107     m_maxILRPdepth = uiMaxDepth;
     101    UInt maxDepth = 0;
     102    if( isILRP )
     103    {
     104      while( ( uiMaxCuWidth >> maxDepth ) > 16 )
     105      {
     106        maxDepth++;
     107      }
     108    }
     109
     110    m_maxILRPdepth = ( ( uiMaxCuWidth >> sps.getMaxTotalCUDepth() ) > 16 && isILRP ) ? maxDepth : sps.getMaxTotalCUDepth();
    108111
    109112    UInt* piTmp = &m_auiZscanToRaster[0];
     
    112115    initRasterToPelXY( uiMaxCuWidth, uiMaxCuHeight, m_maxILRPdepth + 1, m_auiRasterToPelX, m_auiRasterToPelY );
    113116  }
    114 #else
    115   const UInt         uiMaxDepth      = sps.getMaxTotalCUDepth();
    116 #endif
    117   const Window& conformanceWindow    = sps.getConformanceWindow();
    118117
    119118  m_layerId = layerId;
    120119
    121120#if REDUCED_ENCODER_MEMORY
    122   m_picSym.create( sps, pps, uiMaxDepth, bCreateForImmediateReconstruction, layerId );
     121  m_picSym.create( sps, pps, m_maxILRPdepth, bCreateForImmediateReconstruction, layerId );
    123122  if (bCreateEncoderSourcePicYuv)
    124123#else
    125   m_picSym.create( sps, pps, uiMaxDepth, layerId );
     124  m_picSym.create( sps, pps, m_maxILRPdepth, layerId );
    126125
    127126  if (!bIsVirtual)
Note: See TracChangeset for help on using the changeset viewer.