Changeset 1330 in SHVCSoftware for branches/SHM-dev/source/Lib


Ignore:
Timestamp:
22 Jul 2015, 01:27:17 (9 years ago)
Author:
seregin
Message:

port rev 4408

Location:
branches/SHM-dev/source/Lib
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-dev/source/Lib/TLibCommon/CommonDef.h

    r1328 r1330  
    199199// Explicit temporal layer QP offset
    200200#define MAX_TLAYER                  7           ///< max number of temporal layer
    201 #define HB_LAMBDA_FOR_LDC           1           ///< use of B-style lambda for non-key pictures in low-delay mode
    202201
    203202// Fast estimation of generalized B in low-delay mode
  • branches/SHM-dev/source/Lib/TLibEncoder/TEncCfg.h

    r1329 r1330  
    224224  Bool      m_bFastUDIUseMPMEnabled;
    225225  Bool      m_bFastMEForGenBLowDelayEnabled;
     226  Bool      m_bUseBLambdaForNonKeyLowDelayPictures;
    226227  Bool      m_usePCM;
    227228  Int       m_PCMBitDepth[MAX_NUM_CHANNEL_TYPE];
     
    644645  Void      setFastUDIUseMPMEnabled         ( Bool  b )     { m_bFastUDIUseMPMEnabled = b; }
    645646  Void      setFastMEForGenBLowDelayEnabled ( Bool  b )     { m_bFastMEForGenBLowDelayEnabled = b; }
     647  Void      setUseBLambdaForNonKeyLowDelayPictures ( Bool b ) { m_bUseBLambdaForNonKeyLowDelayPictures = b; }
     648
    646649  Void      setPCMInputBitDepthFlag         ( Bool  b )     { m_bPCMInputBitDepthFlag = b; }
    647650  Void      setPCMFilterDisableFlag         ( Bool  b )     {  m_bPCMFilterDisableFlag = b; }
     
    668671  Bool      getFastUDIUseMPMEnabled         ()      { return m_bFastUDIUseMPMEnabled; }
    669672  Bool      getFastMEForGenBLowDelayEnabled ()      { return m_bFastMEForGenBLowDelayEnabled; }
     673  Bool      getUseBLambdaForNonKeyLowDelayPictures () { return m_bUseBLambdaForNonKeyLowDelayPictures; }
    670674  Bool      getPCMInputBitDepthFlag         ()      { return m_bPCMInputBitDepthFlag;   }
    671675  Bool      getPCMFilterDisableFlag         ()      { return m_bPCMFilterDisableFlag;   }
  • branches/SHM-dev/source/Lib/TLibEncoder/TEncSlice.cpp

    r1329 r1330  
    445445  setUpLambda(rpcSlice, dLambda, iQP);
    446446#endif
    447 #if HB_LAMBDA_FOR_LDC
    448   // restore original slice type
    449 
    450   if(!(isField && pocLast == 1) || !m_pcCfg->getEfficientFieldIRAPEnabled())
    451   {
     447
     448  if (m_pcCfg->getFastMEForGenBLowDelayEnabled())
     449  {
     450    // restore original slice type
     451
     452    if(!(isField && pocLast == 1) || !m_pcCfg->getEfficientFieldIRAPEnabled())
     453    {
    452454#if ALLOW_RECOVERY_POINT_AS_RAP
    453     if(m_pcCfg->getDecodingRefreshType() == 3)
    454     {
    455       eSliceType = (pocLast == 0 || (pocCurr)                     % m_pcCfg->getIntraPeriod() == 0 || m_pcGOPEncoder->getGOPSize() == 0) ? I_SLICE : eSliceType;
    456     }
    457     else
    458     {
    459 #endif
    460       eSliceType = (pocLast == 0 || (pocCurr - (isField ? 1 : 0)) % m_pcCfg->getIntraPeriod() == 0 || m_pcGOPEncoder->getGOPSize() == 0) ? I_SLICE : eSliceType;
     455      if(m_pcCfg->getDecodingRefreshType() == 3)
     456      {
     457        eSliceType = (pocLast == 0 || (pocCurr)                     % m_pcCfg->getIntraPeriod() == 0 || m_pcGOPEncoder->getGOPSize() == 0) ? I_SLICE : eSliceType;
     458      }
     459      else
     460      {
     461#endif
     462        eSliceType = (pocLast == 0 || (pocCurr - (isField ? 1 : 0)) % m_pcCfg->getIntraPeriod() == 0 || m_pcGOPEncoder->getGOPSize() == 0) ? I_SLICE : eSliceType;
    461463#if ALLOW_RECOVERY_POINT_AS_RAP
    462     }
    463 #endif
    464   }
    465 
    466 #if SVC_EXTENSION
    467   if( m_pcCfg->getLayerId() > 0 && m_pcCfg->getNumActiveRefLayers() > 0 )
    468   {
    469     eSliceType=B_SLICE;
    470   }
    471 #endif
    472   rpcSlice->setSliceType        ( eSliceType );
    473 #endif
     464      }
     465#endif
     466    }
     467
     468#if SVC_EXTENSION
     469    if( m_pcCfg->getLayerId() > 0 && m_pcCfg->getNumActiveRefLayers() > 0 )
     470    {
     471      eSliceType=B_SLICE;
     472    }
     473#endif
     474
     475    rpcSlice->setSliceType        ( eSliceType );
     476  }
    474477
    475478  if (m_pcCfg->getUseRecalculateQPAccordingToLambda())
Note: See TracChangeset for help on using the changeset viewer.