diff --git a/source/Lib/TLibEncoder/TEncSearch.cpp b/source/Lib/TLibEncoder/TEncSearch.cpp
index da704f0..c94122e 100644
a
|
b
|
Void TEncSearch::predInterSearch( TComDataCU* pcCU, TComYuv* pcOrgYuv, TComYuv*& |
2359 | 2359 | #if DCM_COMB_LIST |
2360 | 2360 | UInt uiCostTempL0[MAX_NUM_REF]; |
2361 | 2361 | for (Int iNumRef=0; iNumRef < MAX_NUM_REF; iNumRef++) uiCostTempL0[iNumRef] = MAX_UINT; |
| 2362 | UInt uiBitsTempL0[MAX_NUM_REF]; |
2362 | 2363 | #endif |
2363 | 2364 | |
2364 | 2365 | xGetBlkBits( ePartSize, pcCU->getSlice()->isInterP(), iPartIdx, uiLastMode, uiMbBits); |
… |
… |
Void TEncSearch::predInterSearch( TComDataCU* pcCU, TComYuv* pcOrgYuv, TComYuv*& |
2432 | 2433 | #endif |
2433 | 2434 | { |
2434 | 2435 | #if DCM_COMB_LIST |
2435 | | if (pcCU->getSlice()->getNumRefIdx(REF_PIC_LIST_C) > 0 && !pcCU->getSlice()->getNoBackPredFlag()) |
2436 | | { |
2437 | | uiCostTemp = uiCostTempL0[pcCU->getSlice()->getRefIdxOfL0FromRefIdxOfL1(iRefIdxTemp)]; |
2438 | | } |
2439 | | else |
2440 | | { |
2441 | | uiCostTemp = MAX_UINT; |
2442 | | } |
2443 | 2436 | #else |
2444 | 2437 | uiCostTemp = MAX_UINT; |
2445 | 2438 | #endif |
… |
… |
Void TEncSearch::predInterSearch( TComDataCU* pcCU, TComYuv* pcOrgYuv, TComYuv*& |
2457 | 2450 | cMvTemp[1][iRefIdxTemp] = cMvTemp[0][pcCU->getSlice()->getRefIdxOfL0FromRefIdxOfL1(iRefIdxTemp)]; |
2458 | 2451 | } |
2459 | 2452 | #endif |
| 2453 | uiCostTemp = uiCostTempL0[pcCU->getSlice()->getRefIdxOfL0FromRefIdxOfL1(iRefIdxTemp)]; |
| 2454 | /*first subtract the bit-rate part of the cost of the other list*/ |
| 2455 | uiCostTemp -= m_pcRdCost->getCost( uiBitsTempL0[pcCU->getSlice()->getRefIdxOfL0FromRefIdxOfL1(iRefIdxTemp)] ); |
| 2456 | /*correct the bit-rate part of the current ref*/ |
| 2457 | m_pcRdCost->setPredictor ( cMvPred[iRefList][iRefIdxTemp] ); |
| 2458 | uiBitsTemp += m_pcRdCost->getBits( cMvTemp[1][iRefIdxTemp].getHor(), cMvTemp[1][iRefIdxTemp].getVer() ); |
| 2459 | /*calculate the correct cost*/ |
| 2460 | uiCostTemp += m_pcRdCost->getCost( uiBitsTemp ); |
2460 | 2461 | } |
2461 | 2462 | else |
2462 | 2463 | { |
… |
… |
Void TEncSearch::predInterSearch( TComDataCU* pcCU, TComYuv* pcOrgYuv, TComYuv*& |
2490 | 2491 | if(iRefList==REF_PIC_LIST_0) |
2491 | 2492 | { |
2492 | 2493 | uiCostTempL0[iRefIdxTemp] = uiCostTemp; |
| 2494 | uiBitsTempL0[iRefIdxTemp] = uiBitsTemp; |
2493 | 2495 | if(pcCU->getSlice()->getRefIdxOfLC(REF_PIC_LIST_0, iRefIdxTemp)<0) |
2494 | 2496 | { |
2495 | 2497 | uiCostTemp = MAX_UINT; |