Changeset 1393 in SHVCSoftware
- Timestamp:
- 4 Aug 2015, 03:17:26 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-dev/source/Lib/TLibCommon/TComPrediction.cpp
r1368 r1393 502 502 Int iHeight; 503 503 UInt uiPartAddr; 504 const TComSlice *pSlice = pcCU->getSlice(); 505 const SliceType sliceType = pSlice->getSliceType(); 506 const TComPPS &pps = *(pSlice->getPPS()); 504 507 505 508 if ( iPartIdx >= 0 ) … … 508 511 if ( eRefPicList != REF_PIC_LIST_X ) 509 512 { 510 if( pcCU->getSlice()->getPPS()->getUseWP())513 if( (sliceType == P_SLICE && pps.getUseWP()) || (sliceType == B_SLICE && pps.getWPBiPred())) 511 514 { 512 515 xPredInterUni (pcCU, uiPartAddr, iWidth, iHeight, eRefPicList, pcYuvPred, true ); 516 xWeightedPredictionUni( pcCU, pcYuvPred, uiPartAddr, iWidth, iHeight, eRefPicList, pcYuvPred ); 513 517 } 514 518 else … … 516 520 xPredInterUni (pcCU, uiPartAddr, iWidth, iHeight, eRefPicList, pcYuvPred ); 517 521 } 518 if ( pcCU->getSlice()->getPPS()->getUseWP() ) 519 { 522 } 523 else 524 { 525 if ( xCheckIdenticalMotion( pcCU, uiPartAddr ) ) 526 { 527 xPredInterUni (pcCU, uiPartAddr, iWidth, iHeight, REF_PIC_LIST_0, pcYuvPred ); 528 } 529 else 530 { 531 xPredInterBi (pcCU, uiPartAddr, iWidth, iHeight, pcYuvPred ); 532 } 533 } 534 return; 535 } 536 537 for ( iPartIdx = 0; iPartIdx < pcCU->getNumPartitions(); iPartIdx++ ) 538 { 539 pcCU->getPartIndexAndSize( iPartIdx, uiPartAddr, iWidth, iHeight ); 540 541 if ( eRefPicList != REF_PIC_LIST_X ) 542 { 543 if( (sliceType == P_SLICE && pps.getUseWP()) || (sliceType == B_SLICE && pps.getWPBiPred())) 544 { 545 xPredInterUni (pcCU, uiPartAddr, iWidth, iHeight, eRefPicList, pcYuvPred, true ); 520 546 xWeightedPredictionUni( pcCU, pcYuvPred, uiPartAddr, iWidth, iHeight, eRefPicList, pcYuvPred ); 521 547 } 522 }523 else524 {525 if ( xCheckIdenticalMotion( pcCU, uiPartAddr ) )526 {527 xPredInterUni (pcCU, uiPartAddr, iWidth, iHeight, REF_PIC_LIST_0, pcYuvPred );528 }529 548 else 530 549 { 531 xPredInterBi (pcCU, uiPartAddr, iWidth, iHeight, pcYuvPred );532 }533 }534 return;535 }536 537 for ( iPartIdx = 0; iPartIdx < pcCU->getNumPartitions(); iPartIdx++ )538 {539 pcCU->getPartIndexAndSize( iPartIdx, uiPartAddr, iWidth, iHeight );540 541 if ( eRefPicList != REF_PIC_LIST_X )542 {543 if( pcCU->getSlice()->getPPS()->getUseWP())544 {545 xPredInterUni (pcCU, uiPartAddr, iWidth, iHeight, eRefPicList, pcYuvPred, true );546 }547 else548 {549 550 xPredInterUni (pcCU, uiPartAddr, iWidth, iHeight, eRefPicList, pcYuvPred ); 550 }551 if ( pcCU->getSlice()->getPPS()->getUseWP() )552 {553 xWeightedPredictionUni( pcCU, pcYuvPred, uiPartAddr, iWidth, iHeight, eRefPicList, pcYuvPred );554 551 } 555 552 }
Note: See TracChangeset for help on using the changeset viewer.