Changeset 1328 in SHVCSoftware for branches/SHM-dev/source/Lib
- Timestamp:
- 22 Jul 2015, 00:52:14 (9 years ago)
- Location:
- branches/SHM-dev/source/Lib
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-dev/source/Lib/TLibCommon/CommonDef.h
r1326 r1328 202 202 203 203 // Fast estimation of generalized B in low-delay mode 204 #define GPB_SIMPLE 1 ///< Simple GPB mode205 #if GPB_SIMPLE206 204 #define GPB_SIMPLE_UNI 1 ///< Simple mode for uni-direction 207 #endif208 205 209 206 // Adaptive search range depending on POC difference -
branches/SHM-dev/source/Lib/TLibEncoder/TEncCfg.h
r1327 r1328 223 223 Bool m_bUseConstrainedIntraPred; 224 224 Bool m_bFastUDIUseMPMEnabled; 225 Bool m_bFastMEForGenBLowDelayEnabled; 225 226 Bool m_usePCM; 226 227 Int m_PCMBitDepth[MAX_NUM_CHANNEL_TYPE]; … … 641 642 Void setUseConstrainedIntraPred ( Bool b ) { m_bUseConstrainedIntraPred = b; } 642 643 Void setFastUDIUseMPMEnabled ( Bool b ) { m_bFastUDIUseMPMEnabled = b; } 644 Void setFastMEForGenBLowDelayEnabled ( Bool b ) { m_bFastMEForGenBLowDelayEnabled = b; } 643 645 Void setPCMInputBitDepthFlag ( Bool b ) { m_bPCMInputBitDepthFlag = b; } 644 646 Void setPCMFilterDisableFlag ( Bool b ) { m_bPCMFilterDisableFlag = b; } … … 664 666 Bool getUseConstrainedIntraPred () { return m_bUseConstrainedIntraPred; } 665 667 Bool getFastUDIUseMPMEnabled () { return m_bFastUDIUseMPMEnabled; } 668 Bool getFastMEForGenBLowDelayEnabled () { return m_bFastMEForGenBLowDelayEnabled; } 666 669 Bool getPCMInputBitDepthFlag () { return m_bPCMInputBitDepthFlag; } 667 670 Bool getPCMFilterDisableFlag () { return m_bPCMFilterDisableFlag; } -
branches/SHM-dev/source/Lib/TLibEncoder/TEncSearch.cpp
r1326 r1328 2250 2250 Int numModesAvailable = 35; //total number of Intra modes 2251 2251 UInt uiRdModeList[FAST_UDI_MAX_RDMODE_NUM]; 2252 Int numModesForFullRD = g_aucIntraModeNumFast[ uiWidthBit ];2252 Int numModesForFullRD = m_pcEncCfg->getFastUDIUseMPMEnabled()?g_aucIntraModeNumFast_UseMPM[ uiWidthBit ] : g_aucIntraModeNumFast_NotUseMPM[ uiWidthBit ]; 2253 2253 2254 2254 if (tuRecurseWithPU.ProcessComponentSection(COMPONENT_Y)) … … 2338 2338 } 2339 2339 2340 #if FAST_UDI_USE_MPM 2340 if (m_pcEncCfg->getFastUDIUseMPMEnabled()) 2341 { 2341 2342 #if FAST_INTRA_SHVC == 0 2342 Int uiPreds[NUM_MOST_PROBABLE_MODES] = {-1, -1, -1};2343 2344 Int iMode = -1;2345 pcCU->getIntraDirPredictor( uiPartOffset, uiPreds, COMPONENT_Y, &iMode );2346 #endif 2347 const Int numCand = ( iMode >= 0 ) ? iMode : Int(NUM_MOST_PROBABLE_MODES);2348 2349 for( Int j=0; j < numCand; j++)2350 {2351 Bool mostProbableModeIncluded = false;2352 Int mostProbableMode = uiPreds[j];2353 2354 for( Int i=0; i < numModesForFullRD; i++)2355 {2356 mostProbableModeIncluded |= (mostProbableMode == uiRdModeList[i]);2357 }2358 if (!mostProbableModeIncluded)2359 {2360 uiRdModeList[numModesForFullRD++] = mostProbableMode;2361 }2362 }2363 #endif // FAST_UDI_USE_MPM 2343 Int uiPreds[NUM_MOST_PROBABLE_MODES] = {-1, -1, -1}; 2344 2345 Int iMode = -1; 2346 pcCU->getIntraDirPredictor( uiPartOffset, uiPreds, COMPONENT_Y, &iMode ); 2347 #endif 2348 const Int numCand = ( iMode >= 0 ) ? iMode : Int(NUM_MOST_PROBABLE_MODES); 2349 2350 for( Int j=0; j < numCand; j++) 2351 { 2352 Bool mostProbableModeIncluded = false; 2353 Int mostProbableMode = uiPreds[j]; 2354 2355 for( Int i=0; i < numModesForFullRD; i++) 2356 { 2357 mostProbableModeIncluded |= (mostProbableMode == uiRdModeList[i]); 2358 } 2359 if (!mostProbableModeIncluded) 2360 { 2361 uiRdModeList[numModesForFullRD++] = mostProbableMode; 2362 } 2363 } 2364 } 2364 2365 } 2365 2366 else … … 3149 3150 uiBitsTemp += m_auiMVPIdxCost[aaiMvpIdx[iRefList][iRefIdxTemp]][AMVP_MAX_NUM_CANDS]; 3150 3151 3151 #if GPB_SIMPLE_UNI 3152 if ( iRefList == 1 ) // list 1 3152 if ( m_pcEncCfg->getFastMEForGenBLowDelayEnabled() && iRefList == 1 ) // list 1 3153 3153 { 3154 3154 if ( pcCU->getSlice()->getList1IdxToList0Idx( iRefIdxTemp ) >= 0 ) … … 3173 3173 xMotionEstimation ( pcCU, pcOrgYuv, iPartIdx, eRefPicList, &cMvPred[iRefList][iRefIdxTemp], iRefIdxTemp, cMvTemp[iRefList][iRefIdxTemp], uiBitsTemp, uiCostTemp ); 3174 3174 } 3175 #else3176 xMotionEstimation ( pcCU, pcOrgYuv, iPartIdx, eRefPicList, &cMvPred[iRefList][iRefIdxTemp], iRefIdxTemp, cMvTemp[iRefList][iRefIdxTemp], uiBitsTemp, uiCostTemp );3177 #endif3178 3175 xCopyAMVPInfo(pcCU->getCUMvField(eRefPicList)->getAMVPInfo(), &aacAMVPInfo[iRefList][iRefIdxTemp]); // must always be done ( also when AMVP_MODE = AM_NONE ) 3179 3176 xCheckBestMVP(pcCU, eRefPicList, cMvTemp[iRefList][iRefIdxTemp], cMvPred[iRefList][iRefIdxTemp], aaiMvpIdx[iRefList][iRefIdxTemp], uiBitsTemp, uiCostTemp);
Note: See TracChangeset for help on using the changeset viewer.