Changeset 373 in 3DVCSoftware for branches/HTM-6.2-dev2-Qualcomm
- Timestamp:
- 5 May 2013, 05:25:40 (12 years ago)
- Location:
- branches/HTM-6.2-dev2-Qualcomm
- Files:
-
- 2 added
- 57 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-6.2-dev2-Qualcomm/CommonTestConditionsCfgs/baseCfg_2view+depth.cfg
r296 r373 192 192 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 193 193 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 194 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)194 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 195 195 InterViewSkip : 0 # interview SKIP mode 196 196 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/CommonTestConditionsCfgs/baseCfg_2view.cfg
r210 r373 186 186 MultiviewMvRegMode : 0 # use original depth maps for regularizing inter-view motion vector 187 187 MultiviewMvRegLambdaScale : 0.0 # lambda scale factor for inter-view motion vector regularization 188 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)188 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 189 189 InterViewSkip : 0 # interview SKIP mode 190 190 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/CommonTestConditionsCfgs/baseCfg_3view+depth.cfg
r296 r373 196 196 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 197 197 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 198 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)198 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 199 199 InterViewSkip : 0 # interview SKIP mode 200 200 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/CommonTestConditionsCfgs/baseCfg_3view.cfg
r210 r373 188 188 MultiviewMvRegMode : 0 # use original depth maps for regularizing inter-view motion vector 189 189 MultiviewMvRegLambdaScale : 0.0 # lambda scale factor for inter-view motion vector regularization 190 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)190 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 191 191 InterViewSkip : 0 # interview SKIP mode 192 192 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/cfg/IBPsetting_balloons.cfg
r297 r373 199 199 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 200 200 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 201 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)201 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 202 202 InterViewSkip : 0 # interview SKIP mode 203 203 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/cfg/IBPsetting_gtfly.cfg
r297 r373 199 199 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 200 200 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 201 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)201 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 202 202 InterViewSkip : 0 # interview SKIP mode 203 203 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/cfg/IBPsetting_kendo.cfg
r297 r373 199 199 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 200 200 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 201 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)201 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 202 202 InterViewSkip : 0 # interview SKIP mode 203 203 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/cfg/IBPsetting_news.cfg
r297 r373 199 199 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 200 200 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 201 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)201 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 202 202 InterViewSkip : 0 # interview SKIP mode 203 203 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/cfg/IBPsetting_poznanhall.cfg
r297 r373 199 199 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 200 200 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 201 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)201 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 202 202 InterViewSkip : 0 # interview SKIP mode 203 203 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/cfg/IBPsetting_poznanstreet.cfg
r297 r373 199 199 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 200 200 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 201 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)201 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 202 202 InterViewSkip : 0 # interview SKIP mode 203 203 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/cfg/IBPsetting_undodancer.cfg
r297 r373 199 199 MultiviewMvRegMode : 1 # use original depth maps for regularizing inter-view motion vector 200 200 MultiviewMvRegLambdaScale : 1.0 # lambda scale factor for inter-view motion vector regularization 201 MultiviewResPred : 1 # inter-view residual prediction (0:off, 1:on)201 MultiviewResPred : 1 # advanced inter-view residual prediction (0:off, 1:on) 202 202 InterViewSkip : 0 # interview SKIP mode 203 203 InterViewSkipLambdaScale : 8 # lambda scale for inter-view skip mode -
branches/HTM-6.2-dev2-Qualcomm/source/App/TAppEncoder/TAppEncCfg.cpp
r332 r373 383 383 #endif 384 384 #if H3D_IVRP 385 #if QC_ARP_D0177 386 ("MultiviewResPred", m_nUseAdvResPred, (UInt)0, "usage of Advanced residual prediction" ) 387 #else 385 388 ("MultiviewResPred", m_uiMultiviewResPredMode, (UInt)0, "usage of inter-view residual prediction" ) 389 #endif 386 390 #endif 387 391 … … 917 921 #endif 918 922 #if H3D_IVRP 923 #if QC_ARP_D0177 924 xConfirmPara ( m_nUseAdvResPred < 0 || m_nUseAdvResPred > 1 , "0<=ARP<=1" ); 925 #else 919 926 xConfirmPara ( m_uiMultiviewResPredMode > 1, "MultiviewResPred must be less than or equal to 1" ); 920 927 xConfirmPara ( m_uiMultiviewResPredMode > 0 && m_uiPredDepthMapGeneration == 0 , "MultiviewResPred > 0 requires PredDepthMapGen > 0" ); 928 #endif 921 929 #endif 922 930 if( m_bUsingDepthMaps ) … … 1672 1680 printf("IVSEnable: %d ", m_bUseIVS); 1673 1681 #endif 1682 #if QC_ARP_D0177 1683 printf(" ARP:%d " , m_nUseAdvResPred ); 1684 #endif 1674 1685 printf("\n"); 1675 1686 -
branches/HTM-6.2-dev2-Qualcomm/source/App/TAppEncoder/TAppEncCfg.h
r332 r373 217 217 Double m_dMultiviewMvRegLambdaScale; ///< lambda scale for multiview motion vectors regularization 218 218 #endif 219 #if H3D_IVRP 219 #if H3D_IVRP 220 #if QC_ARP_D0177 221 UInt m_nUseAdvResPred; 222 #else 220 223 UInt m_uiMultiviewResPredMode; ///< using multiview residual prediction 224 #endif 221 225 #endif 222 226 -
branches/HTM-6.2-dev2-Qualcomm/source/App/TAppEncoder/TAppEncTop.cpp
r332 r373 223 223 #endif 224 224 #if H3D_IVRP 225 #if QC_ARP_D0177 226 m_acTEncTopList[iViewIdx]->setUseAdvRP ( iViewIdx ? m_nUseAdvResPred : 0 ); 227 m_acTEncTopList[iViewIdx]->setARPStepNum ( iViewIdx ? QC_ARP_WFNR : 1 ); 228 #else 225 229 m_acTEncTopList[iViewIdx]->setMultiviewResPredMode ( m_uiMultiviewResPredMode ); 230 #endif 226 231 #endif 227 232 … … 560 565 m_acTEncDepthTopList[iViewIdx]->setMultiviewMvRegLambdaScale ( 0.0 ); 561 566 #endif 562 #if H3D_IVRP 563 m_acTEncDepthTopList[iViewIdx]->setMultiviewResPredMode ( 0 ); 567 #if H3D_IVRP 568 #if QC_ARP_D0177 569 m_acTEncDepthTopList[iViewIdx]->setUseAdvRP ( 0 ); 570 m_acTEncDepthTopList[iViewIdx]->setARPStepNum ( 1 ); 571 #else 572 m_acTEncDepthTopList[iViewIdx]->setMultiviewResPredMode ( 0 ); 573 #endif 564 574 #endif 565 575 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/ContextTables.h
r332 r373 487 487 #endif 488 488 }; 489 #if QC_ARP_D0177 490 #define NUM_ARPW_CTX 4 ///< number of context models for generalized residual prediction weighting factor 491 static const UChar 492 INIT_ARPW[3][NUM_ARPW_CTX] = 493 { 494 { 154 , 154 , 154 , 154 }, 495 { 154 , 154 , 154 , 154 }, 496 { 154 , 154 , 154 , 154 }, 497 }; 498 #endif 489 499 490 500 #if LGE_EDGE_INTRA_A0070 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComDataCU.cpp
r351 r373 225 225 m_pbResPredFlag = NULL; 226 226 #endif 227 #if QC_ARP_D0177 228 m_puhARPW = NULL; 229 #endif 227 230 #if LGE_EDGE_INTRA_A0070 228 231 m_pucEdgeCode = NULL; … … 301 304 m_pbResPredAvailable = (Bool* )xMalloc(Bool, uiNumPartition); 302 305 m_pbResPredFlag = (Bool* )xMalloc(Bool, uiNumPartition); 306 #if QC_ARP_D0177 307 m_puhARPW = new UChar[ uiNumPartition]; 308 #endif 303 309 #endif 304 310 m_puhLumaIntraDir = (UChar* )xMalloc(UChar, uiNumPartition); … … 463 469 if ( m_pDvInfo ) { xFree(m_pDvInfo); m_pDvInfo = NULL; } 464 470 #endif 471 #if QC_ARP_D0177 472 if ( m_puhARPW ) { delete[] m_puhARPW; m_puhARPW = NULL; } 473 #endif 465 474 if ( m_puhLumaIntraDir ) { xFree(m_puhLumaIntraDir); m_puhLumaIntraDir = NULL; } 466 475 if ( m_puhChromaIntraDir ) { xFree(m_puhChromaIntraDir); m_puhChromaIntraDir = NULL; } … … 636 645 m_pbSDCFlag[ui] = pcFrom->getSDCFlag(ui); 637 646 #endif 647 #if QC_ARP_D0177 648 m_puhARPW[ui] = pcFrom->getARPW( ui ); 649 #endif 638 650 m_puhWidth [ui] = pcFrom->getWidth(ui); 639 651 m_puhHeight [ui] = pcFrom->getHeight(ui); … … 733 745 memset( m_pbResPredFlag + firstElement, 0 , sizeof( Bool ) * numElements ); 734 746 #endif 747 #if QC_ARP_D0177 748 memset( m_puhARPW + firstElement, 0 , sizeof( UChar ) * numElements ); 749 #endif 735 750 } 736 751 … … 875 890 m_pbResPredFlag[ui] = 0; 876 891 #endif 892 #if QC_ARP_D0177 893 m_puhARPW[ui] = 0; 894 #endif 877 895 m_puhLumaIntraDir[ui] = 2; 878 896 m_puhChromaIntraDir[ui] = 0; … … 985 1003 memset( m_pbResPredAvailable, 0, iSizeInBool ); 986 1004 memset( m_pbResPredFlag, 0, iSizeInBool ); 1005 #endif 1006 #if QC_ARP_D0177 1007 memset( m_puhARPW, 0, iSizeInUchar ); 987 1008 #endif 988 1009 memset( m_puhLumaIntraDir, 2, iSizeInUchar ); … … 1102 1123 m_pbResPredFlag [ui] = pcCU->m_pbResPredFlag [ uiPartOffset + ui ]; 1103 1124 #endif 1125 #if QC_ARP_D0177 1126 m_puhARPW [ui] = pcCU->getARPW( uiPartOffset+ui ); 1127 #endif 1104 1128 #if RWTH_SDC_DLT_B0036 1105 1129 m_pbSDCFlag [ui] = pcCU->m_pbSDCFlag [ uiPartOffset + ui ]; … … 1224 1248 m_pbResPredFlag = pcCU->getResPredFlag () + uiPart; 1225 1249 #endif 1250 #if QC_ARP_D0177 1251 m_puhARPW = pcCU->getARPW() + uiPart; 1252 #endif 1226 1253 m_puhLumaIntraDir = pcCU->getLumaIntraDir() + uiPart; 1227 1254 m_puhChromaIntraDir = pcCU->getChromaIntraDir() + uiPart; … … 1392 1419 m_pbResPredFlag = pcCU->getResPredFlag () + uiAbsPartIdx; 1393 1420 #endif 1421 #if QC_ARP_D0177 1422 m_puhARPW = pcCU->getARPW() + uiAbsPartIdx; 1423 #endif 1394 1424 m_apiMVPIdx[eRefPicList] = pcCU->getMVPIdx(eRefPicList) + uiAbsPartIdx; 1395 1425 m_apiMVPNum[eRefPicList] = pcCU->getMVPNum(eRefPicList) + uiAbsPartIdx; … … 1409 1439 // Copy small CU to bigger CU. 1410 1440 // One of quarter parts overwritten by predicted sub part. 1411 Void TComDataCU::copyPartFrom( TComDataCU* pcCU, UInt uiPartUnitIdx, UInt uiDepth ) 1441 Void TComDataCU::copyPartFrom( TComDataCU* pcCU, UInt uiPartUnitIdx, UInt uiDepth 1442 #if QC_ARP_D0177 1443 , 1444 Bool bRP 1445 #endif 1446 ) 1412 1447 { 1413 1448 assert( uiPartUnitIdx<4 ); … … 1446 1481 memcpy( m_pbResPredFlag + uiOffset, pcCU->getResPredFlag(), iSizeInBool ); 1447 1482 #endif 1483 #if QC_ARP_D0177 1484 memcpy( m_puhARPW + uiOffset, pcCU->getARPW(), iSizeInUchar ); 1485 #endif 1448 1486 memcpy( m_puhLumaIntraDir + uiOffset, pcCU->getLumaIntraDir(), iSizeInUchar ); 1449 1487 memcpy( m_puhChromaIntraDir + uiOffset, pcCU->getChromaIntraDir(), iSizeInUchar ); … … 1522 1560 1523 1561 #if LGE_EDGE_INTRA_A0070 1562 #if QC_ARP_D0177 1563 if( !bRP && pcCU->getSlice()->getSPS()->isDepth() ) 1564 #else 1524 1565 if( getSlice()->getSPS()->isDepth() ) 1566 #endif 1525 1567 { 1526 1568 memcpy( getEdgeCode( uiOffset ), pcCU->getEdgeCode(0), iSizeInUchar * LGE_EDGE_INTRA_MAX_EDGE_NUM_PER_4x4 ); … … 1588 1630 memcpy( rpcCU->getResPredFlag() + m_uiAbsIdxInLCU, m_pbResPredFlag, iSizeInBool ); 1589 1631 #endif 1632 #if QC_ARP_D0177 1633 memcpy( rpcCU->getARPW() + m_uiAbsIdxInLCU, m_puhARPW, iSizeInUchar ); 1634 #endif 1590 1635 memcpy( rpcCU->getLumaIntraDir() + m_uiAbsIdxInLCU, m_puhLumaIntraDir, iSizeInUchar ); 1591 1636 memcpy( rpcCU->getChromaIntraDir() + m_uiAbsIdxInLCU, m_puhChromaIntraDir, iSizeInUchar ); … … 1718 1763 memcpy( rpcCU->getResPredAvail() + uiPartOffset, m_pbResPredAvailable, iSizeInBool ); 1719 1764 memcpy( rpcCU->getResPredFlag() + uiPartOffset, m_pbResPredFlag, iSizeInBool ); 1765 #endif 1766 #if QC_ARP_D0177 1767 memcpy( rpcCU->getARPW() + uiPartOffset, m_puhARPW, iSizeInUchar ); 1720 1768 #endif 1721 1769 memcpy( rpcCU->getLumaIntraDir() + uiPartOffset, m_puhLumaIntraDir, iSizeInUchar ); … … 2709 2757 return uiCtx; 2710 2758 } 2711 2759 #if QC_ARP_D0177 2760 UInt TComDataCU::getCTXARPWFlag( UInt uiAbsPartIdx ) 2761 { 2762 TComDataCU* pcTempCU; 2763 UInt uiTempPartIdx; 2764 UInt uiCtx = 0; 2765 2766 pcTempCU = getPULeft( uiTempPartIdx, m_uiAbsIdxInLCU + uiAbsPartIdx ); 2767 uiCtx = ( pcTempCU ) ? ((pcTempCU->getARPW( uiTempPartIdx )==0)?0:1) : 0; 2768 2769 pcTempCU = getPUAbove( uiTempPartIdx, m_uiAbsIdxInLCU + uiAbsPartIdx ); 2770 uiCtx += ( pcTempCU ) ? ((pcTempCU->getARPW( uiTempPartIdx )==0)?0:1): 0; 2771 2772 return uiCtx; 2773 } 2774 #endif 2712 2775 #if LGE_ILLUCOMP_B0045 2713 2776 UInt TComDataCU::getCtxICFlag( UInt uiAbsPartIdx ) … … 3632 3695 #endif //H3D_NBDV 3633 3696 3634 #if H3D_IVRP 3697 #if H3D_IVRP & !QC_ARP_D0177 3635 3698 Bool bDVAvail = true; 3636 3699 #endif … … 3689 3752 cDisInfo.m_aVIdxCan[0] = 0; 3690 3753 #endif 3691 #if H3D_IVRP 3754 #if H3D_IVRP & !QC_ARP_D0177 3692 3755 bDVAvail = false; 3693 3756 #endif … … 3752 3815 iPdmDir[1] = iPdmInterDir; 3753 3816 #endif // H3D_NBDV 3754 #if H3D_IVRP 3817 #if H3D_IVRP & !QC_ARP_D0177 3755 3818 if (m_pcSlice->getSPS()->getMultiviewResPredMode()==1 && iPdmDir[0] && !bNoPdmMerge && cCurPS == SIZE_2Nx2N && bDVAvail) 3756 3819 { … … 7278 7341 TComDataCU::getResidualSamples( UInt uiPartIdx, Bool bRecon, TComYuv* pcYuv ) 7279 7342 { 7343 #if !QC_ARP_D0177 7280 7344 TComResidualGenerator* pcResidualGenerator = m_pcSlice->getSPS()->getResidualGenerator(); 7281 7345 ROFRS( pcResidualGenerator, false ); 7346 #endif 7347 7282 7348 #if H3D_NBDV 7283 7349 DisInfo cDisInfo; … … 7308 7374 #if !QC_CU_NBDV_D0181 7309 7375 getDisMvpCandNBDV( 0, 0, &cDisInfo, false ); 7310 7311 7376 if( cDisInfo.iN == 0) 7312 7377 #else … … 7326 7391 } 7327 7392 else 7393 #if QC_ARP_D0177 7394 if(m_pcSlice->getSPS()->getUseAdvRP()) 7395 { 7396 m_pePartSize[0] = m_peSaved; 7397 return true; 7398 } 7399 else 7400 return false; 7401 #else 7328 7402 { 7329 7403 Bool bAvailable = pcResidualGenerator->getResidualSamples( this, uiPartIdx, pcYuv, cDisInfo.m_acMvCand[0], bRecon ); … … 7331 7405 return bAvailable; 7332 7406 } 7407 #endif 7333 7408 #else 7334 7409 return pcResidualGenerator->getResidualSamples( this, uiPartIdx, pcYuv, bRecon ); … … 7336 7411 } 7337 7412 #endif 7338 7413 #if QC_ARP_D0177 7414 Void TComDataCU::setARPWSubParts ( UChar w, UInt uiAbsPartIdx, UInt uiDepth ) 7415 { 7416 assert( sizeof( *m_puhARPW) == 1 ); 7417 memset( m_puhARPW + uiAbsPartIdx, w, m_pcPic->getNumPartInCU() >> ( 2 * uiDepth ) ); 7418 } 7419 #endif 7339 7420 #if LGE_EDGE_INTRA_A0070 7340 7421 Void TComDataCU::reconPartition( UInt uiAbsPartIdx, UInt uiDepth, Bool bLeft, UChar ucStartPos, UChar ucNumEdge, UChar* pucEdgeCode, Bool* pbRegion ) -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComDataCU.h
r351 r373 214 214 Bool* m_pbResPredFlag; ///< array of residual prediction flags 215 215 #endif 216 216 #if QC_ARP_D0177 217 UChar* m_puhARPW; 218 #endif 217 219 #if LGE_EDGE_INTRA_A0070 218 220 UChar* m_pucEdgeCode; ///< array of edge code … … 301 303 302 304 /// compute scaling factor from POC difference 305 #if !QC_ARP_D0177 303 306 Int xGetDistScaleFactor ( Int iCurrPOC, Int iCurrRefPOC, Int iColPOC, Int iColRefPOC ); 304 307 #endif 305 308 Void xDeriveCenterIdx( PartSize eCUMode, UInt uiPartIdx, UInt& ruiPartIdxCenter ); 306 309 Bool xGetCenterCol( UInt uiPartIdx, RefPicList eRefPicList, int iRefIdx, TComMv *pcMv ); … … 316 319 // create / destroy / initialize / copy 317 320 // ------------------------------------------------------------------------------------------------------------------- 318 321 #if QC_ARP_D0177 322 Int xGetDistScaleFactor ( Int iCurrPOC, Int iCurrRefPOC, Int iColPOC, Int iColRefPOC ); 323 #endif 324 319 325 Void create ( UInt uiNumPartition, UInt uiWidth, UInt uiHeight, Bool bDecSubCu, Int unitSize 320 326 #if ADAPTIVE_QP_SELECTION … … 337 343 #endif 338 344 ); 339 Void copyPartFrom ( TComDataCU* pcCU, UInt uiPartUnitIdx, UInt uiDepth ); 345 Void copyPartFrom ( TComDataCU* pcCU, UInt uiPartUnitIdx, UInt uiDepth 346 #if QC_ARP_D0177 347 , 348 Bool bRP = false 349 #endif 350 ); 340 351 341 352 Void copyToPic ( UChar uiDepth ); … … 585 596 Bool getResidualSamples( UInt uiPartIdx, Bool bRecon, TComYuv* pcYuv = 0 ); 586 597 #endif 598 #if QC_ARP_D0177 599 UChar* getARPW () { return m_puhARPW; } 600 UChar getARPW ( UInt uiIdx ) { return m_puhARPW[uiIdx]; } 601 Void setARPW ( UInt uiIdx, UChar w ) { m_puhARPW[uiIdx] = w; } 602 Void setARPWSubParts ( UChar w, UInt uiAbsPartIdx, UInt uiDepth ); 603 Double getARPWFactor ( UInt uiIdx ); 604 #endif 587 605 // ------------------------------------------------------------------------------------------------------------------- 588 606 // member functions for accessing partition information … … 705 723 UInt getCtxResPredFlag ( UInt uiAbsPartIdx ); 706 724 #endif 707 725 #if QC_ARP_D0177 726 UInt getCTXARPWFlag ( UInt uiAbsPartIdx ); 727 #endif 708 728 UInt getSliceStartCU ( UInt pos ) { return m_uiSliceStartCU[pos-m_uiAbsIdxInLCU]; } 709 729 UInt getEntropySliceStartCU ( UInt pos ) { return m_uiEntropySliceStartCU[pos-m_uiAbsIdxInLCU]; } -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComDepthMapGenerator.h
r332 r373 80 80 81 81 UInt getPdm () { if( m_aacActiveSPS[0][1] ) { return m_aacActiveSPS[0][1]->getPredDepthMapGeneration(); } return 0; } 82 #if H3D_IVRP 82 #if H3D_IVRP & !QC_ARP_D0177 83 83 UInt getResPrd () { if( m_aacActiveSPS[0][1] ) { return m_aacActiveSPS[0][1]->getMultiviewResPredMode (); } return 0; } 84 84 #endif -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComInterpolationFilter.cpp
r56 r373 72 72 { -2, 10, 58, -2 } 73 73 }; 74 74 #if QC_ARP_D0177 75 const Short TComInterpolationFilter::m_lumaFilterARP[4][NTAPS_LUMA_ARP] = 76 { 77 {64, 0}, 78 {48, 16}, 79 {32, 32}, 80 {16, 48} 81 }; 82 const Short TComInterpolationFilter::m_chromaFilterARP[8][NTAPS_CHROMA_ARP] = 83 { 84 {64, 0}, 85 {56, 8}, 86 {48, 16}, 87 {40, 24}, 88 {32, 32}, 89 {24, 40}, 90 {16, 48}, 91 {8, 56} 92 }; 93 #endif 75 94 // ==================================================================================================================== 76 95 // Private member functions … … 320 339 * \param isLast Flag indicating whether it is the last filtering operation 321 340 */ 322 Void TComInterpolationFilter::filterHorLuma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isLast ) 341 Void TComInterpolationFilter::filterHorLuma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isLast 342 #if QC_ARP_D0177 343 , 344 Bool filterType 345 #endif 346 ) 323 347 { 324 348 assert(frac >= 0 && frac < 4); … … 330 354 else 331 355 { 332 filterHor<NTAPS_LUMA>(src, srcStride, dst, dstStride, width, height, isLast, m_lumaFilter[frac]); 356 #if QC_ARP_D0177 357 if(filterType) 358 filterHor<NTAPS_LUMA_ARP>(src, srcStride, dst, dstStride, width, height, isLast, m_lumaFilterARP[frac]); 359 else 360 #endif 361 filterHor<NTAPS_LUMA>(src, srcStride, dst, dstStride, width, height, isLast, m_lumaFilter[frac]); 333 362 } 334 363 } … … 347 376 * \param isLast Flag indicating whether it is the last filtering operation 348 377 */ 349 Void TComInterpolationFilter::filterVerLuma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isFirst, Bool isLast ) 378 Void TComInterpolationFilter::filterVerLuma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isFirst, Bool isLast 379 #if QC_ARP_D0177 380 , 381 Bool filterType 382 #endif 383 ) 350 384 { 351 385 assert(frac >= 0 && frac < 4); … … 357 391 else 358 392 { 359 filterVer<NTAPS_LUMA>(src, srcStride, dst, dstStride, width, height, isFirst, isLast, m_lumaFilter[frac]); 393 #if QC_ARP_D0177 394 if(filterType) 395 filterVer<NTAPS_LUMA_ARP>(src, srcStride, dst, dstStride, width, height, isFirst, isLast, m_lumaFilterARP[frac]); 396 else 397 #endif 398 filterVer<NTAPS_LUMA>(src, srcStride, dst, dstStride, width, height, isFirst, isLast, m_lumaFilter[frac]); 360 399 } 361 400 } … … 373 412 * \param isLast Flag indicating whether it is the last filtering operation 374 413 */ 375 Void TComInterpolationFilter::filterHorChroma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isLast ) 414 Void TComInterpolationFilter::filterHorChroma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isLast 415 #if QC_ARP_D0177 416 , 417 Bool filterType 418 #endif 419 ) 376 420 { 377 421 assert(frac >= 0 && frac < 8); … … 383 427 else 384 428 { 429 #if QC_ARP_D0177 430 if(filterType) 431 filterHor<NTAPS_CHROMA_ARP>(src, srcStride, dst, dstStride, width, height, isLast, m_chromaFilterARP[frac]); 432 else 433 #endif 385 434 filterHor<NTAPS_CHROMA>(src, srcStride, dst, dstStride, width, height, isLast, m_chromaFilter[frac]); 386 435 } … … 400 449 * \param isLast Flag indicating whether it is the last filtering operation 401 450 */ 402 Void TComInterpolationFilter::filterVerChroma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isFirst, Bool isLast ) 451 Void TComInterpolationFilter::filterVerChroma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isFirst, Bool isLast 452 #if QC_ARP_D0177 453 , 454 Bool filterType 455 #endif 456 ) 403 457 { 404 458 assert(frac >= 0 && frac < 8); … … 410 464 else 411 465 { 412 filterVer<NTAPS_CHROMA>(src, srcStride, dst, dstStride, width, height, isFirst, isLast, m_chromaFilter[frac]); 466 #if QC_ARP_D0177 467 if(filterType) 468 filterVer<NTAPS_CHROMA_ARP>(src, srcStride, dst, dstStride, width, height, isFirst, isLast, m_chromaFilterARP[frac]); 469 else 470 #endif 471 filterVer<NTAPS_CHROMA>(src, srcStride, dst, dstStride, width, height, isFirst, isLast, m_chromaFilter[frac]); 413 472 } 414 473 } -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComInterpolationFilter.h
r56 r373 44 44 //! \ingroup TLibCommon 45 45 //! \{ 46 #if QC_ARP_D0177 47 #define NTAPS_LUMA_ARP 2 ///< Number of taps for luma 48 #define NTAPS_CHROMA_ARP 2 ///< Number of taps for chroma 49 #endif 46 50 47 51 #define NTAPS_LUMA 8 ///< Number of taps for luma … … 58 62 static const Short m_lumaFilter[4][NTAPS_LUMA]; ///< Luma filter taps 59 63 static const Short m_chromaFilter[8][NTAPS_CHROMA]; ///< Chroma filter taps 60 64 #if QC_ARP_D0177 65 static const Short m_lumaFilterARP [4][NTAPS_LUMA_ARP]; ///< Luma filter taps 66 static const Short m_chromaFilterARP[8][NTAPS_CHROMA_ARP]; ///< Chroma filter taps 67 #endif 68 61 69 static Void filterCopy(const Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Bool isFirst, Bool isLast); 62 70 … … 73 81 ~TComInterpolationFilter() {} 74 82 75 Void filterHorLuma (Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isLast ); 76 Void filterVerLuma (Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isFirst, Bool isLast ); 77 Void filterHorChroma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isLast ); 78 Void filterVerChroma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isFirst, Bool isLast ); 83 Void filterHorLuma (Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isLast 84 #if QC_ARP_D0177 85 , 86 Bool filterType = 0 87 #endif 88 ); 89 Void filterVerLuma (Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isFirst, Bool isLast 90 #if QC_ARP_D0177 91 , 92 Bool filterType = 0 93 #endif 94 ); 95 Void filterHorChroma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isLast 96 #if QC_ARP_D0177 97 , 98 Bool filterType = 0 99 #endif 100 ); 101 Void filterVerChroma(Pel *src, Int srcStride, Short *dst, Int dstStride, Int width, Int height, Int frac, Bool isFirst, Bool isLast 102 #if QC_ARP_D0177 103 , 104 Bool filterType = 0 105 #endif 106 ); 79 107 }; 80 108 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComPicYuv.cpp
r332 r373 488 488 } 489 489 } 490 490 #if QC_ARP_D0177 491 Void TComPicYuv::clearPic() 492 { 493 ::memset ( m_apiPicBufY, 0 , sizeof (Pel) * ( m_iPicWidth + (m_iLumaMarginX << 1)) * ( m_iPicHeight + (m_iLumaMarginY << 1)) ); 494 ::memset ( m_apiPicBufU, 0 , sizeof (Pel) * ((m_iPicWidth >> 1) + (m_iChromaMarginX << 1)) * ((m_iPicHeight >> 1) + (m_iChromaMarginY << 1)) ); 495 ::memset ( m_apiPicBufV, 0 , sizeof (Pel) * ((m_iPicWidth >> 1) + (m_iChromaMarginX << 1)) * ((m_iPicHeight >> 1) + (m_iChromaMarginY << 1)) ); 496 } 497 #endif 491 498 //! \} -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComPicYuv.h
r56 r373 183 183 Void setLumaTo ( Pel pVal ); 184 184 Void setChromaTo ( Pel pVal ); 185 185 #if QC_ARP_D0177 186 Void clearPic(); 187 #endif 186 188 };// END CLASS DEFINITION TComPicYuv 187 189 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComPrediction.cpp
r332 r373 78 78 79 79 m_cYuvPredTemp.destroy(); 80 80 #if QC_ARP_D0177 81 m_acYuvPredBase[0].destroy(); 82 m_acYuvPredBase[1].destroy(); 83 m_acYuvDiff[0].destroy(); 84 m_acYuvDiff[1].destroy(); 85 #endif 81 86 if( m_pLumaRecBuffer ) 82 87 { … … 119 124 120 125 m_cYuvPredTemp.create( g_uiMaxCUWidth, g_uiMaxCUHeight ); 126 #if QC_ARP_D0177 127 m_acYuvPredBase[0] .create( g_uiMaxCUWidth, g_uiMaxCUHeight ); 128 m_acYuvPredBase[1] .create( g_uiMaxCUWidth, g_uiMaxCUHeight ); 129 m_acYuvDiff [0] .create( g_uiMaxCUWidth, g_uiMaxCUHeight ); 130 m_acYuvDiff [1] .create( g_uiMaxCUWidth, g_uiMaxCUHeight ); 131 #endif 121 132 } 122 133 … … 751 762 } 752 763 753 #if H3D_IVRP 764 #if H3D_IVRP & !QC_ARP_D0177 754 765 Void TComPrediction::residualPrediction(TComDataCU* pcCU, TComYuv* pcYuvPred, TComYuv* pcYuvResPred) 755 766 { … … 810 821 } 811 822 #endif 812 823 #if QC_ARP_D0177 824 if( pcCU->getSlice()->getSPS()->isDepth() == false 825 && pcCU->getSlice()->getSPS()->getViewId() > 0 826 && pcCU->getSlice()->getSPS()->getUseAdvRP() > 0 827 && pcCU->getARPW( uiPartAddr ) > 0 828 && pcCU->getSlice()->getRefPic( eRefPicList, iRefIdx )->getPOC()!= pcCU->getSlice()->getPOC() 829 && (pcCU->getPartitionSize(uiPartAddr)==SIZE_2Nx2N || pcCU->isSkipped(uiPartAddr)) 830 ) 831 { 832 xPredInterUniARP( pcCU , uiPartAddr , iWidth , iHeight , eRefPicList , rpcYuvPred , iPartIdx , bi ); 833 } 834 else 835 { 836 #endif 813 837 #if HHI_FULL_PEL_DEPTH_MAP_MV_ACC 814 838 if( pcCU->getSlice()->getSPS()->isDepth() ) … … 911 935 } 912 936 #endif 913 } 914 937 #if QC_ARP_D0177 938 } 939 #endif 940 } 941 942 #if QC_ARP_D0177 943 Void TComPrediction::xPredInterUniARP( TComDataCU* pcCU, UInt uiPartAddr, Int iWidth, Int iHeight, RefPicList eRefPicList, TComYuv*& rpcYuvPred, Int iPartIdx, Bool bi, TComMvField * pNewMvFiled ) 944 { 945 Int iRefIdx = pcCU->getCUMvField( eRefPicList )->getRefIdx( uiPartAddr ); 946 TComMv cMv = pcCU->getCUMvField( eRefPicList )->getMv( uiPartAddr ); 947 Bool bTobeScaled = false; 948 UChar dW = pcCU->getARPW ( uiPartAddr ); 949 TComPic* pcPicYuvBaseCol = NULL; 950 TComPic* pcPicYuvBaseRef = NULL; 951 DisInfo cDistparity; 952 953 if( pNewMvFiled ) 954 { 955 iRefIdx = pNewMvFiled->getRefIdx(); 956 cMv = pNewMvFiled->getMv(); 957 } 958 959 #if QC_CU_NBDV_D0181 960 cDistparity.bDV = pcCU->getDvInfo(uiPartAddr).bDV; 961 if( cDistparity.bDV ) 962 { 963 #if MERL_VSP_C0152 964 cDistparity.m_acMvCand[0] = pcCU->getDvInfo(0).m_acMvCandNoRef[0]; 965 #else 966 cDistparity.m_acMvCand[0] = pcCU->getDvInfo(0).m_acMvCand[0]; 967 #endif 968 assert(pcCU->getDvInfo(uiPartAddr).bDV == pcCU->getDvInfo(0).bDV); 969 cDistparity.m_aVIdxCan[0] = pcCU->getDvInfo(uiPartAddr).m_aVIdxCan[0]; 970 cDistparity.iN = pcCU->getDvInfo(uiPartAddr).iN; 971 } 972 else 973 cDistparity.iN = 0; 974 #else 975 pcCU->getDisMvpCandNBDV( iPartIdx, uiPartAddr, &cDistparity, false ); 976 #endif 977 978 dW = !cDistparity.iN ? 0: dW; 979 if( cDistparity.iN ) 980 { 981 if(dW > 0 && pcCU->getSlice()->getRefPic( eRefPicList, 0 )->getPOC()!= pcCU->getSlice()->getPOC()) 982 bTobeScaled = true; 983 pcPicYuvBaseCol = pcCU->getSlice()->getBaseViewRefPic( pcCU->getSlice()->getPOC(), cDistparity.m_aVIdxCan[0] ); 984 pcPicYuvBaseRef = pcCU->getSlice()->getBaseViewRefPic( pcCU->getSlice()->getRefPic( eRefPicList, 0 )->getPOC(), cDistparity.m_aVIdxCan[0] ); 985 if( (!pcPicYuvBaseCol || pcPicYuvBaseCol->getPOC() != pcCU->getSlice()->getPOC()) || (!pcPicYuvBaseRef || pcPicYuvBaseRef->getPOC() != pcCU->getSlice()->getRefPic( eRefPicList, 0 )->getPOC() )) 986 { 987 dW = 0; 988 bTobeScaled = false; 989 } 990 else 991 assert( pcPicYuvBaseCol->getPOC() == pcCU->getSlice()->getPOC() && pcPicYuvBaseRef->getPOC() == pcCU->getSlice()->getRefPic( eRefPicList, 0 )->getPOC() ); 992 if(bTobeScaled) 993 { 994 Int iCurrPOC = pcCU->getSlice()->getPOC(); 995 Int iColRefPOC = pcCU->getSlice()->getRefPOC( eRefPicList, iRefIdx ); 996 Int iCurrRefPOC = pcCU->getSlice()->getRefPOC( eRefPicList, 0); 997 Int iScale = pcCU-> xGetDistScaleFactor(iCurrPOC, iCurrRefPOC, iCurrPOC, iColRefPOC); 998 if ( iScale != 4096 ) 999 cMv = cMv.scaleMv( iScale ); 1000 iRefIdx = 0; 1001 } 1002 } 1003 pcCU->clipMv(cMv); 1004 TComPicYuv* pcPicYuvRef = pcCU->getSlice()->getRefPic( eRefPicList, iRefIdx )->getPicYuvRec(); 1005 xPredInterLumaBlk ( pcCU, pcPicYuvRef, uiPartAddr, &cMv, iWidth, iHeight, rpcYuvPred, bi 1006 #if LGE_ILLUCOMP_B0045 1007 , false 1008 #endif 1009 , true 1010 ); 1011 xPredInterChromaBlk( pcCU, pcPicYuvRef, uiPartAddr, &cMv, iWidth, iHeight, rpcYuvPred, bi 1012 #if LGE_ILLUCOMP_B0045 1013 , false 1014 #endif 1015 , true 1016 ); 1017 if( dW > 0 ) 1018 { 1019 TComYuv * pYuvmB0 = &m_acYuvPredBase[0]; 1020 TComYuv * pYuvB1 = &m_acYuvPredBase[1]; 1021 assert ( cDistparity.iN == 1 ); 1022 pcPicYuvRef = pcPicYuvBaseCol->getPicYuvRec(); 1023 xPredInterLumaBlk ( pcCU, pcPicYuvRef, uiPartAddr, &cDistparity.m_acMvCand[0], iWidth, iHeight, pYuvB1, bi 1024 #if LGE_ILLUCOMP_B0045 1025 , false 1026 #endif 1027 , true 1028 ); 1029 xPredInterChromaBlk( pcCU, pcPicYuvRef, uiPartAddr, &cDistparity.m_acMvCand[0], iWidth, iHeight, pYuvB1, bi 1030 #if LGE_ILLUCOMP_B0045 1031 , false 1032 #endif 1033 , true 1034 ); 1035 pcPicYuvRef = pcPicYuvBaseRef->getPicYuvRec(); 1036 TComMv cMVwithDisparity = cMv + cDistparity.m_acMvCand[0]; 1037 pcCU->clipMv(cMVwithDisparity); 1038 xPredInterLumaBlk ( pcCU, pcPicYuvRef, uiPartAddr, &cMVwithDisparity, iWidth, iHeight, pYuvmB0, bi 1039 #if LGE_ILLUCOMP_B0045 1040 , false 1041 #endif 1042 , true 1043 ); 1044 xPredInterChromaBlk( pcCU, pcPicYuvRef, uiPartAddr, &cMVwithDisparity, iWidth, iHeight, pYuvmB0, bi 1045 #if LGE_ILLUCOMP_B0045 1046 , false 1047 #endif 1048 , true 1049 ); 1050 pYuvB1->subtractARP( pYuvB1 , pYuvmB0 , uiPartAddr , iWidth , iHeight ); 1051 if(dW == 2) 1052 pYuvB1->multiplyARP( uiPartAddr , iWidth , iHeight , dW ); 1053 rpcYuvPred->addARP( rpcYuvPred , pYuvB1 , uiPartAddr , iWidth , iHeight , !bi ); 1054 } 1055 } 1056 #endif 915 1057 916 1058 #if MERL_VSP_C0152 … … 1108 1250 */ 1109 1251 #if LGE_ILLUCOMP_B0045 1110 Void TComPrediction::xPredInterLumaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi, Bool bICFlag) 1111 #else 1112 Void TComPrediction::xPredInterLumaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi ) 1252 Void TComPrediction::xPredInterLumaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi, Bool bICFlag 1253 #if QC_ARP_D0177 1254 , 1255 Int filterType 1256 #endif 1257 ) 1258 #else 1259 Void TComPrediction::xPredInterLumaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi 1260 #if QC_ARP_D0177 1261 , 1262 Int filterType 1263 #endif 1264 ) 1113 1265 #endif 1114 1266 { … … 1129 1281 if ( yFrac == 0 ) 1130 1282 { 1131 m_if.filterHorLuma( ref, refStride, dst, dstStride, width, height, xFrac, !bi ); 1283 m_if.filterHorLuma( ref, refStride, dst, dstStride, width, height, xFrac, !bi 1284 #if QC_ARP_D0177 1285 , 1286 filterType 1287 #endif 1288 ); 1132 1289 } 1133 1290 else if ( xFrac == 0 ) 1134 1291 { 1135 m_if.filterVerLuma( ref, refStride, dst, dstStride, width, height, yFrac, true, !bi ); 1292 m_if.filterVerLuma( ref, refStride, dst, dstStride, width, height, yFrac, true, !bi 1293 #if QC_ARP_D0177 1294 , 1295 filterType 1296 #endif 1297 ); 1136 1298 } 1137 1299 else … … 1143 1305 Int halfFilterSize = ( filterSize >> 1 ); 1144 1306 1145 m_if.filterHorLuma(ref - (halfFilterSize-1)*refStride, refStride, tmp, tmpStride, width, height+filterSize-1, xFrac, false ); 1146 m_if.filterVerLuma(tmp + (halfFilterSize-1)*tmpStride, tmpStride, dst, dstStride, width, height, yFrac, false, !bi); 1307 m_if.filterHorLuma(ref - (halfFilterSize-1)*refStride, refStride, tmp, tmpStride, width, height+filterSize-1, xFrac, false 1308 #if QC_ARP_D0177 1309 , 1310 filterType 1311 #endif 1312 ); 1313 m_if.filterVerLuma(tmp + (halfFilterSize-1)*tmpStride, tmpStride, dst, dstStride, width, height, yFrac, false, !bi 1314 #if QC_ARP_D0177 1315 , 1316 filterType 1317 #endif 1318 ); 1147 1319 } 1148 1320 … … 1185 1357 */ 1186 1358 #if LGE_ILLUCOMP_B0045 1187 Void TComPrediction::xPredInterChromaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi, Bool bICFlag ) 1188 #else 1189 Void TComPrediction::xPredInterChromaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi ) 1359 Void TComPrediction::xPredInterChromaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi, Bool bICFlag 1360 #if QC_ARP_D0177 1361 , 1362 Int filterType 1363 #endif 1364 ) 1365 #else 1366 Void TComPrediction::xPredInterChromaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi 1367 #if QC_ARP_D0177 1368 , Int filterType 1369 #endif 1370 ) 1190 1371 #endif 1191 1372 { … … 1215 1396 if ( yFrac == 0 ) 1216 1397 { 1217 m_if.filterHorChroma(refCb, refStride, dstCb, dstStride, cxWidth, cxHeight, xFrac, !bi); 1218 m_if.filterHorChroma(refCr, refStride, dstCr, dstStride, cxWidth, cxHeight, xFrac, !bi); 1398 m_if.filterHorChroma(refCb, refStride, dstCb, dstStride, cxWidth, cxHeight, xFrac, !bi 1399 #if QC_ARP_D0177 1400 , 1401 filterType 1402 #endif 1403 ); 1404 m_if.filterHorChroma(refCr, refStride, dstCr, dstStride, cxWidth, cxHeight, xFrac, !bi 1405 #if QC_ARP_D0177 1406 , 1407 filterType 1408 #endif 1409 ); 1219 1410 } 1220 1411 else if ( xFrac == 0 ) 1221 1412 { 1222 m_if.filterVerChroma(refCb, refStride, dstCb, dstStride, cxWidth, cxHeight, yFrac, true, !bi); 1223 m_if.filterVerChroma(refCr, refStride, dstCr, dstStride, cxWidth, cxHeight, yFrac, true, !bi); 1413 m_if.filterVerChroma(refCb, refStride, dstCb, dstStride, cxWidth, cxHeight, yFrac, true, !bi 1414 #if QC_ARP_D0177 1415 , 1416 filterType 1417 #endif 1418 ); 1419 m_if.filterVerChroma(refCr, refStride, dstCr, dstStride, cxWidth, cxHeight, yFrac, true, !bi 1420 #if QC_ARP_D0177 1421 , 1422 filterType 1423 #endif 1424 ); 1224 1425 } 1225 1426 else 1226 1427 { 1227 m_if.filterHorChroma(refCb - (halfFilterSize-1)*refStride, refStride, extY, extStride, cxWidth, cxHeight+filterSize-1, xFrac, false); 1228 m_if.filterVerChroma(extY + (halfFilterSize-1)*extStride, extStride, dstCb, dstStride, cxWidth, cxHeight , yFrac, false, !bi); 1428 m_if.filterHorChroma(refCb - (halfFilterSize-1)*refStride, refStride, extY, extStride, cxWidth, cxHeight+filterSize-1, xFrac, false 1429 #if QC_ARP_D0177 1430 , 1431 filterType 1432 #endif 1433 ); 1434 m_if.filterVerChroma(extY + (halfFilterSize-1)*extStride, extStride, dstCb, dstStride, cxWidth, cxHeight , yFrac, false, !bi 1435 #if QC_ARP_D0177 1436 , 1437 filterType 1438 #endif 1439 ); 1229 1440 1230 m_if.filterHorChroma(refCr - (halfFilterSize-1)*refStride, refStride, extY, extStride, cxWidth, cxHeight+filterSize-1, xFrac, false); 1231 m_if.filterVerChroma(extY + (halfFilterSize-1)*extStride, extStride, dstCr, dstStride, cxWidth, cxHeight , yFrac, false, !bi); 1441 m_if.filterHorChroma(refCr - (halfFilterSize-1)*refStride, refStride, extY, extStride, cxWidth, cxHeight+filterSize-1, xFrac, false 1442 #if QC_ARP_D0177 1443 , 1444 filterType 1445 #endif 1446 ); 1447 m_if.filterVerChroma(extY + (halfFilterSize-1)*extStride, extStride, dstCr, dstStride, cxWidth, cxHeight , yFrac, false, !bi 1448 #if QC_ARP_D0177 1449 , 1450 filterType 1451 #endif 1452 ); 1232 1453 } 1233 1454 #if LGE_ILLUCOMP_B0045 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComPrediction.h
r332 r373 69 69 TComYuv m_acYuvPred[2]; 70 70 TComYuv m_cYuvPredTemp; 71 #if QC_ARP_D0177 72 TComYuv m_acYuvPredBase[2]; 73 TComYuv m_acYuvDiff[2]; 74 #endif 71 75 TComYuv m_filteredBlock[4][4]; 72 76 TComYuv m_filteredBlockTmp[4]; … … 86 90 87 91 // motion compensation functions 92 #if QC_ARP_D0177 93 Void xPredInterUniARP ( TComDataCU* pcCU, UInt uiPartAddr, Int iWidth, Int iHeight, RefPicList eRefPicList, TComYuv*& rpcYuvPred, Int iPartIdx, Bool bi=false, TComMvField * pNewMvFiled = NULL ); 94 #endif 88 95 #if MERL_VSP_C0152 89 96 Void xPredInterUni ( TComDataCU* pcCU, UInt uiPartAddr, UInt uiAbsPartIdx, Int iWidth, Int iHeight, RefPicList eRefPicList, TComYuv*& rpcYuvPred, Int iPartIdx, Bool bPrdDepthMap, UInt uiSubSampExpX = 0, UInt uiSubSampExpY = 0, Bool bi=false ); … … 113 120 114 121 #if LGE_ILLUCOMP_B0045 115 Void xPredInterLumaBlk ( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi, Bool bICFlag = false ); 116 Void xPredInterChromaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi, Bool bICFlag = false ); 117 #else 118 Void xPredInterLumaBlk ( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi ); 119 Void xPredInterChromaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi ); 122 Void xPredInterLumaBlk ( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi, Bool bICFlag = false 123 #if QC_ARP_D0177 124 , 125 Int filterType = 0 126 #endif 127 ); 128 Void xPredInterChromaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi, Bool bICFlag = false 129 #if QC_ARP_D0177 130 , 131 Int filterType = 0 132 #endif 133 ); 134 #else 135 Void xPredInterLumaBlk ( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi 136 #if QC_ARP_D0177 137 , 138 Int filterType = 0 139 #endif 140 ); 141 Void xPredInterChromaBlk( TComDataCU *cu, TComPicYuv *refPic, UInt partAddr, TComMv *mv, Int width, Int height, TComYuv *&dstPic, Bool bi 142 #if QC_ARP_D0177 143 , 144 Int filterType = 0 145 #endif 146 ); 120 147 #endif 121 148 Void xWeightedAverage ( TComDataCU* pcCU, TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, Int iRefIdx0, Int iRefIdx1, UInt uiPartAddr, Int iWidth, Int iHeight, TComYuv*& rpcYuvDst ); … … 169 196 #endif 170 197 171 #if H3D_IVRP 198 #if H3D_IVRP & !QC_ARP_D0177 172 199 Void residualPrediction (TComDataCU* pcCU, TComYuv* pcYuvPred, TComYuv* pcYuvResPred); 173 200 #endif -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComResidualGenerator.cpp
r351 r373 44 44 45 45 46 #if H3D_IVRP 46 #if H3D_IVRP & !QC_ARP_D0177 47 47 48 48 … … 225 225 } 226 226 } 227 227 #endif 228 229 #if !QC_ARP_D0177 228 230 #if H3D_NBDV 229 231 Bool … … 249 251 } 250 252 251 #if H3D_NBDV 253 #if H3D_NBDV 252 254 Bool 253 255 TComResidualGenerator::getResidualSamples( TComPic* pcPic, UInt uiXPos, UInt uiYPos, UInt uiBlkWidth, UInt uiBlkHeight, TComYuv* pcYuv, TComMv iDisp, Bool bRecon) … … 263 265 } 264 266 UInt uiXPosInRefView = uiXPos , uiYPosInRefView = uiYPos; 267 #if QC_ARP_D0177 268 if(pcPic->getSPS()->getMultiviewResPredMode()) 269 { 270 #endif 265 271 #if H3D_NBDV 266 272 xSetPredResidualBlock( pcPic, uiBaseViewId, uiXPos, uiYPos, uiBlkWidth, uiBlkHeight, pcYuv, iDisp, &uiXPosInRefView , &uiYPosInRefView , bRecon ); … … 269 275 #endif 270 276 return true; 277 #if QC_ARP_D0177 278 } 279 else 280 return true; 281 #endif 271 282 } 272 283 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComResidualGenerator.h
r332 r373 50 50 51 51 52 #if H3D_IVRP 52 #if H3D_IVRP & !QC_ARP_D0177 53 53 54 54 class TComResidualGenerator -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComSlice.cpp
r332 r373 1386 1386 } 1387 1387 #endif 1388 1388 #if QC_ARP_D0177 1389 Void TComSlice::setARPStepNum() 1390 { 1391 Bool bAllIvRef = false; 1392 if(!getSPS()->getUseAdvRP()) 1393 m_nARPStepNum = 0; 1394 else 1395 { 1396 for( Int iRefListId = 0; iRefListId < 2; iRefListId++ ) 1397 { 1398 RefPicList eRefPicList = RefPicList( iRefListId ); 1399 Int iNumRefIdx = getNumRefIdx(eRefPicList); 1400 if( iNumRefIdx <= 0 ) 1401 continue; 1402 for (Int i = 0; i < iNumRefIdx; i++) 1403 { 1404 if(getRefPic( REF_PIC_LIST_0, i)->getPOC() != getPOC()) 1405 { 1406 bAllIvRef = true; 1407 break; 1408 } 1409 } 1410 if( bAllIvRef == true ) 1411 break; 1412 } 1413 if(bAllIvRef== true) 1414 m_nARPStepNum = getSPS()->getARPStepNum(); 1415 else 1416 m_nARPStepNum = 0; 1417 } 1418 } 1419 #endif 1389 1420 // ------------------------------------------------------------------------------------------------ 1390 1421 // Video parameter set (VPS) … … 1576 1607 m_uiMultiviewMvPredMode = 0; 1577 1608 #endif 1578 1609 #if QC_ARP_D0177 1610 m_nUseAdvResPred = 0; 1611 m_nARPStepNum = 1; 1612 #endif 1579 1613 ::memset( m_aiUsableInterViewRefs, 0, sizeof( m_aiUsableInterViewRefs ) ); 1580 1614 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComSlice.h
r332 r373 54 54 class TComDepthMapGenerator; 55 55 #endif 56 #if H3D_IVRP 56 #if H3D_IVRP & !QC_ARP_D0177 57 57 class TComResidualGenerator; 58 58 #endif … … 390 390 #endif 391 391 #if H3D_IVRP 392 #if QC_ARP_D0177 393 UInt m_nUseAdvResPred; 394 UInt m_nARPStepNum; 395 #else 392 396 UInt m_uiMultiviewResPredMode; 397 #endif 393 398 #endif 394 399 … … 396 401 TComDepthMapGenerator* m_pcDepthMapGenerator; 397 402 #endif 398 #if H3D_IVRP 403 #if H3D_IVRP & !QC_ARP_D0177 399 404 TComResidualGenerator* m_pcResidualGenerator; 400 405 #endif … … 643 648 Void setPredDepthMapGeneration( UInt uiViewId, Bool bIsDepth, UInt uiPdmGenMode = 0, UInt uiPdmMvPredMode = 0, UInt uiPdmPrec = 0, Int** aaiPdmScaleNomDelta = 0, Int** aaiPdmOffset = 0 ); 644 649 #endif 645 #if H3D_IVRP 650 #if H3D_IVRP & !QC_ARP_D0177 646 651 Void setMultiviewResPredMode ( UInt uiResPrdMode ) { m_uiMultiviewResPredMode = uiResPrdMode; } 647 652 #endif … … 658 663 #endif 659 664 #if H3D_IVRP 665 #if QC_ARP_D0177 666 UInt getUseAdvRP() { return m_nUseAdvResPred; } 667 Void setUseAdvRP(UInt n) { m_nUseAdvResPred = n; } 668 UInt getARPStepNum() { return m_nARPStepNum; } 669 Void setARPStepNum(UInt n) { m_nARPStepNum = n; } 670 #else 660 671 UInt getMultiviewResPredMode () { return m_uiMultiviewResPredMode; } 672 #endif 661 673 #endif 662 674 … … 665 677 TComDepthMapGenerator* getDepthMapGenerator() { return m_pcDepthMapGenerator; } 666 678 #endif 667 #if H3D_IVRP 679 #if H3D_IVRP & !QC_ARP_D0177 668 680 Void setResidualGenerator( TComResidualGenerator* pcResidualGenerator ) { m_pcResidualGenerator = pcResidualGenerator; } 669 681 TComResidualGenerator* getResidualGenerator() { return m_pcResidualGenerator; } … … 1107 1119 Bool m_bApplyIC; 1108 1120 #endif 1121 #if QC_ARP_D0177 1122 TComList<TComPic*> * m_pBaseViewRefPicList[MAX_VIEW_NUM]; 1123 UInt m_nARPStepNum; 1124 #endif 1109 1125 #if INTER_VIEW_VECTOR_SCALING_C0115|QC_MVHEVC_B0046 1110 1126 Bool m_bIVScalingFlag; … … 1253 1269 Void setRefPicListMvc ( TComList<TComPic*>& rcListPic, std::vector<TComPic*>& rapcInterViewRefPics ); 1254 1270 Void setRefPOCnViewListsMvc(); 1255 1271 #if QC_ARP_D0177 1272 Void setBaseViewRefPicList( TComList<TComPic*> *pListPic, Int iViewIdx ) { m_pBaseViewRefPicList[iViewIdx] = pListPic; } 1273 TComPic* getBaseViewRefPic ( UInt uiPOC , Int iViewIdx ) { return xGetRefPic( *m_pBaseViewRefPicList[iViewIdx], uiPOC ); } 1274 Void setARPStepNum(); 1275 UInt getARPStepNum( ) { return m_nARPStepNum; } 1276 #endif 1256 1277 Void setColDir ( UInt uiDir ) { m_uiColDir = uiDir; } 1257 1278 #if COLLOCATED_REF_IDX -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComYuv.cpp
r332 r373 741 741 } 742 742 } 743 #if QC_ARP_D0177 744 Void TComYuv::addARP(TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight , Bool bClip ) 745 { 746 addARPLuma ( pcYuvSrc0, pcYuvSrc1, uiAbsPartIdx, uiWidth , uiHeight , bClip ); 747 addARPChroma ( pcYuvSrc0, pcYuvSrc1, uiAbsPartIdx, uiWidth>>1, uiHeight>>1 , bClip ); 748 } 749 750 Void TComYuv::addARPLuma(TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight , Bool bClip ) 751 { 752 Int x, y; 753 754 Pel* pSrc0 = pcYuvSrc0->getLumaAddr( uiAbsPartIdx ); 755 Pel* pSrc1 = pcYuvSrc1->getLumaAddr( uiAbsPartIdx ); 756 Pel* pDst = getLumaAddr( uiAbsPartIdx ); 757 758 UInt iSrc0Stride = pcYuvSrc0->getStride(); 759 UInt iSrc1Stride = pcYuvSrc1->getStride(); 760 UInt iDstStride = getStride(); 761 for ( y = uiHeight-1; y >= 0; y-- ) 762 { 763 for ( x = uiWidth-1; x >= 0; x-- ) 764 { 765 pDst[x] = pSrc0[x] + pSrc1[x]; 766 if( bClip ) 767 pDst[x] = Clip( pDst[x] ); 768 } 769 pSrc0 += iSrc0Stride; 770 pSrc1 += iSrc1Stride; 771 pDst += iDstStride; 772 } 773 } 774 775 Void TComYuv::addARPChroma(TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight , Bool bClip ) 776 { 777 Int x, y; 778 779 Pel* pSrcU0 = pcYuvSrc0->getCbAddr( uiAbsPartIdx ); 780 Pel* pSrcU1 = pcYuvSrc1->getCbAddr( uiAbsPartIdx ); 781 Pel* pSrcV0 = pcYuvSrc0->getCrAddr( uiAbsPartIdx ); 782 Pel* pSrcV1 = pcYuvSrc1->getCrAddr( uiAbsPartIdx ); 783 Pel* pDstU = getCbAddr( uiAbsPartIdx ); 784 Pel* pDstV = getCrAddr( uiAbsPartIdx ); 785 786 UInt iSrc0Stride = pcYuvSrc0->getCStride(); 787 UInt iSrc1Stride = pcYuvSrc1->getCStride(); 788 UInt iDstStride = getCStride(); 789 for ( y = uiHeight-1; y >= 0; y-- ) 790 { 791 for ( x = uiWidth-1; x >= 0; x-- ) 792 { 793 pDstU[x] = pSrcU0[x] + pSrcU1[x]; 794 pDstV[x] = pSrcV0[x] + pSrcV1[x]; 795 if( bClip ) 796 { 797 pDstU[x] = Clip( pDstU[x] ); 798 pDstV[x] = Clip( pDstV[x] ); 799 } 800 } 801 802 pSrcU0 += iSrc0Stride; 803 pSrcU1 += iSrc1Stride; 804 pSrcV0 += iSrc0Stride; 805 pSrcV1 += iSrc1Stride; 806 pDstU += iDstStride; 807 pDstV += iDstStride; 808 } 809 } 810 811 Void TComYuv::subtractARP(TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight) 812 { 813 subtractARPLuma ( pcYuvSrc0, pcYuvSrc1, uiAbsPartIdx, uiWidth , uiHeight ); 814 subtractARPChroma( pcYuvSrc0, pcYuvSrc1, uiAbsPartIdx, uiWidth>>1 , uiHeight>>1 ); 815 } 816 817 Void TComYuv::subtractARPLuma(TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight) 818 { 819 Int x, y; 820 821 Pel* pSrc0 = pcYuvSrc0->getLumaAddr( uiAbsPartIdx ); 822 Pel* pSrc1 = pcYuvSrc1->getLumaAddr( uiAbsPartIdx ); 823 Pel* pDst = getLumaAddr( uiAbsPartIdx ); 824 825 Int iSrc0Stride = pcYuvSrc0->getStride(); 826 Int iSrc1Stride = pcYuvSrc1->getStride(); 827 Int iDstStride = getStride(); 828 for ( y = uiHeight-1; y >= 0; y-- ) 829 { 830 for ( x = uiWidth-1; x >= 0; x-- ) 831 { 832 pDst[x] = pSrc0[x] - pSrc1[x]; 833 } 834 pSrc0 += iSrc0Stride; 835 pSrc1 += iSrc1Stride; 836 pDst += iDstStride; 837 } 838 } 839 840 Void TComYuv::subtractARPChroma(TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight) 841 { 842 Int x, y; 843 844 Pel* pSrcU0 = pcYuvSrc0->getCbAddr( uiAbsPartIdx ); 845 Pel* pSrcU1 = pcYuvSrc1->getCbAddr( uiAbsPartIdx ); 846 Pel* pSrcV0 = pcYuvSrc0->getCrAddr( uiAbsPartIdx ); 847 Pel* pSrcV1 = pcYuvSrc1->getCrAddr( uiAbsPartIdx ); 848 Pel* pDstU = getCbAddr( uiAbsPartIdx ); 849 Pel* pDstV = getCrAddr( uiAbsPartIdx ); 850 851 Int iSrc0Stride = pcYuvSrc0->getCStride(); 852 Int iSrc1Stride = pcYuvSrc1->getCStride(); 853 Int iDstStride = getCStride(); 854 for ( y = uiHeight-1; y >= 0; y-- ) 855 { 856 for ( x = uiWidth-1; x >= 0; x-- ) 857 { 858 pDstU[x] = pSrcU0[x] - pSrcU1[x]; 859 pDstV[x] = pSrcV0[x] - pSrcV1[x]; 860 } 861 pSrcU0 += iSrc0Stride; 862 pSrcU1 += iSrc1Stride; 863 pSrcV0 += iSrc0Stride; 864 pSrcV1 += iSrc1Stride; 865 pDstU += iDstStride; 866 pDstV += iDstStride; 867 } 868 } 869 870 Void TComYuv::multiplyARP( UInt uiAbsPartIdx , UInt uiWidth , UInt uiHeight , UChar dW ) 871 { 872 multiplyARPLuma( uiAbsPartIdx , uiWidth , uiHeight , dW ); 873 multiplyARPChroma( uiAbsPartIdx , uiWidth >> 1 , uiHeight >> 1 , dW ); 874 } 875 876 Void TComYuv::xxMultiplyLine( Pel * pSrcDst , UInt uiWidth , UChar dW ) 877 { 878 assert( dW == 2 ); 879 for( UInt x = 0 ; x < uiWidth ; x++ ) 880 pSrcDst[x] = pSrcDst[x] >> 1; 881 } 882 883 Void TComYuv::multiplyARPLuma( UInt uiAbsPartIdx , UInt uiWidth , UInt uiHeight , UChar dW ) 884 { 885 Pel* pDst = getLumaAddr( uiAbsPartIdx ); 886 Int iDstStride = getStride(); 887 for ( Int y = uiHeight-1; y >= 0; y-- ) 888 { 889 xxMultiplyLine( pDst , uiWidth , dW ); 890 pDst += iDstStride; 891 } 892 } 893 894 Void TComYuv::multiplyARPChroma( UInt uiAbsPartIdx , UInt uiWidth , UInt uiHeight , UChar dW ) 895 { 896 Pel* pDstU = getCbAddr( uiAbsPartIdx ); 897 Pel* pDstV = getCrAddr( uiAbsPartIdx ); 898 899 Int iDstStride = getCStride(); 900 for ( Int y = uiHeight-1; y >= 0; y-- ) 901 { 902 xxMultiplyLine( pDstU , uiWidth , dW ); 903 xxMultiplyLine( pDstV , uiWidth , dW ); 904 pDstU += iDstStride; 905 pDstV += iDstStride; 906 } 907 } 908 #endif 743 909 //! \} -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TComYuv.h
r332 r373 199 199 200 200 __inline Pel xClip (Pel x ) { return ( (x < 0) ? 0 : (x > (Pel)g_uiIBDI_MAX) ? (Pel)g_uiIBDI_MAX : x ); } 201 #if QC_ARP_D0177 202 Void addARP ( TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight , Bool bClip ); 203 Void addARPLuma ( TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight , Bool bClip ); 204 Void addARPChroma ( TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight , Bool bClip ); 205 Void subtractARP ( TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight ); 206 Void subtractARPLuma ( TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight ); 207 Void subtractARPChroma( TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiAbsPartIdx, UInt uiWidth , UInt uiHeight ); 208 Void multiplyARP ( UInt uiAbsPartIdx , UInt uiWidth , UInt uiHeight , UChar dW ); 209 Void multiplyARPLuma ( UInt uiAbsPartIdx , UInt uiWidth , UInt uiHeight , UChar dW ); 210 Void multiplyARPChroma( UInt uiAbsPartIdx , UInt uiWidth , UInt uiHeight , UChar dW ); 211 private: 212 Void xxMultiplyLine( Pel * pSrcDst , UInt uiWidth , UChar dW ); 213 #endif 201 214 };// END CLASS DEFINITION TComYuv 202 215 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibCommon/TypeDef.h
r351 r373 95 95 // FIX_LG_RESTRICTEDRESPRED_M24766 1 96 96 97 #define QC_ARP_D0177 1 ////< advanced residual prediction 98 #if QC_ARP_D0177 99 #define QC_ARP_WFNR 3 100 #endif 97 101 ///// ***** DISPARITY VECTOR DERIVATION ********* 98 102 #define H3D_NBDV 1 // Neighboring block disparity derivation -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecCAVLC.cpp
r332 r373 1493 1493 #endif 1494 1494 #if H3D_IVRP 1495 pcSPS->setMultiviewResPredMode ( 0 ); 1496 #endif 1495 #if QC_ARP_D0177 1496 pcSPS->setUseAdvRP ( 0 ); 1497 pcSPS->setARPStepNum( 1 ); 1498 #else 1499 pcSPS->setMultiviewResPredMode ( 0 ); 1500 #endif 1501 #endif 1502 1497 1503 } 1498 1504 else … … 1544 1550 #endif 1545 1551 #if H3D_IVRP 1552 #if QC_ARP_D0177 1553 pcSPS->setUseAdvRP ( 0 ); 1554 pcSPS->setARPStepNum( 1 ); 1555 #else 1546 1556 pcSPS->setMultiviewResPredMode ( 0 ); 1547 1557 #endif 1558 #endif 1559 1548 1560 } 1549 1561 else … … 1573 1585 UInt uiMultiviewMvPredMode = 0; 1574 1586 #endif 1575 #if H3D_IVRP 1587 #if H3D_IVRP & !QC_ARP_D0177 1576 1588 UInt uiMultiviewResPredMode = 0; 1577 1589 #endif … … 1588 1600 READ_UVLC( uiMultiviewMvPredMode, "multi_view_mv_pred_mode" ); 1589 1601 #endif 1590 #if H3D_IVRP 1602 #if H3D_IVRP & !QC_ARP_D0177 1591 1603 READ_FLAG( uiMultiviewResPredMode, "multi_view_residual_pred_mode" ); 1592 1604 #endif … … 1599 1611 #endif 1600 1612 #if H3D_IVRP 1613 #if QC_ARP_D0177 1614 READ_FLAG( uiCode , "advanced_residual_pred_flag" ); pcSPS->setUseAdvRP( uiCode ); 1615 if( pcSPS->getUseAdvRP() ) 1616 pcSPS->setARPStepNum( QC_ARP_WFNR ); 1617 else 1618 pcSPS->setARPStepNum( 1 ); 1619 #else 1601 1620 pcSPS->setMultiviewResPredMode ( uiMultiviewResPredMode ); 1602 1621 #endif 1622 #endif 1623 1603 1624 } 1604 1625 } … … 2424 2445 } 2425 2446 #endif 2426 2447 #if QC_ARP_D0177 2448 Void TDecCavlc::parseARPW( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 2449 { 2450 assert( false ); 2451 } 2452 #endif 2427 2453 #if RWTH_SDC_DLT_B0036 2428 2454 Void TDecCavlc::parseSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecCAVLC.h
r332 r373 144 144 Void parseResPredFlag ( TComDataCU* pcCU, Bool& rbResPredFlag, UInt uiAbsPartIdx, UInt uiDepth ); 145 145 #endif 146 #if QC_ARP_D0177 147 Void parseARPW( TComDataCU* pcCU, UInt uiAbsPartIdx,UInt uiDepth ); 148 #endif 146 149 Void parseSplitFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 147 150 Void parsePartSize ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecCu.cpp
r351 r373 54 54 m_ppcYuvResi = NULL; 55 55 m_ppcYuvReco = NULL; 56 #if H3D_IVRP 56 #if H3D_IVRP & !QC_ARP_D0177 57 57 m_ppcYuvResPred = NULL; 58 58 #endif … … 82 82 m_ppcYuvResi = new TComYuv*[m_uiMaxDepth-1]; 83 83 m_ppcYuvReco = new TComYuv*[m_uiMaxDepth-1]; 84 #if H3D_IVRP 84 #if H3D_IVRP & !QC_ARP_D0177 85 85 m_ppcYuvResPred = new TComYuv* [m_uiMaxDepth-1]; 86 86 #endif … … 96 96 m_ppcYuvResi[ui] = new TComYuv; m_ppcYuvResi[ui]->create( uiWidth, uiHeight ); 97 97 m_ppcYuvReco[ui] = new TComYuv; m_ppcYuvReco[ui]->create( uiWidth, uiHeight ); 98 #if H3D_IVRP 98 #if H3D_IVRP & !QC_ARP_D0177 99 99 m_ppcYuvResPred[ui] = new TComYuv; m_ppcYuvResPred[ui]->create( uiWidth, uiHeight ); 100 100 #endif … … 120 120 m_ppcYuvResi[ui]->destroy(); delete m_ppcYuvResi[ui]; m_ppcYuvResi[ui] = NULL; 121 121 m_ppcYuvReco[ui]->destroy(); delete m_ppcYuvReco[ui]; m_ppcYuvReco[ui] = NULL; 122 #if H3D_IVRP 122 #if H3D_IVRP & !QC_ARP_D0177 123 123 m_ppcYuvResPred[ui]->destroy(); delete m_ppcYuvResPred[ui]; m_ppcYuvResPred[ui] = NULL; 124 124 #endif … … 128 128 delete [] m_ppcYuvResi; m_ppcYuvResi = NULL; 129 129 delete [] m_ppcYuvReco; m_ppcYuvReco = NULL; 130 #if H3D_IVRP 130 #if H3D_IVRP & !QC_ARP_D0177 131 131 delete [] m_ppcYuvResPred; m_ppcYuvResPred = NULL; 132 132 #endif … … 317 317 if(!pcCU->getSlice()->isIntra()) 318 318 { 319 #if QC_ARP_D0177 320 if(( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() || pcCU->getSlice()->getSPS()->getUseAdvRP()) && pcCU->getSlice()->getViewId()) 321 #else 319 322 if(( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() || pcCU->getSlice()->getSPS()->getMultiviewResPredMode()) && pcCU->getSlice()->getViewId()) 323 #endif 320 324 { 321 325 m_ppcCU[uiDepth]->copyInterPredInfoFrom( pcCU, uiAbsPartIdx, REF_PIC_LIST_0, true ); … … 443 447 } 444 448 #endif 449 #if QC_ARP_D0177 450 if( pcCU->getSlice()->getSPS()->getUseAdvRP() ) 451 { 452 pcCU->setResPredAvailSubParts ( false, uiAbsPartIdx, 0, uiDepth ); 453 pcCU->setResPredFlagSubParts ( false, uiAbsPartIdx, 0, uiDepth ); 454 m_pcEntropyDecoder->decodeARPW( pcCU , uiAbsPartIdx , uiDepth, m_ppcCU[uiDepth], 0 ); 455 } 456 #endif 445 457 xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast ); 446 458 return; … … 494 506 } 495 507 #endif 496 508 #if QC_ARP_D0177 509 if (pcCU->getSlice()->getSPS()->getUseAdvRP() && pcCU->isIntra( uiAbsPartIdx ) ) 510 { 511 pcCU->setResPredAvailSubParts ( 0, uiAbsPartIdx, 0, uiDepth ); 512 pcCU->setResPredFlagSubParts ( 0, uiAbsPartIdx, 0, uiDepth ); 513 } 514 #endif 497 515 #if HHI_MPI 498 516 if( pcCU->getTextureModeDepth( uiAbsPartIdx ) == uiDepth ) … … 704 722 m_pcPrediction->motionCompensation( pcCU, m_ppcYuvReco[uiDepth] ); 705 723 #endif 706 #if H3D_IVRP 724 #if H3D_IVRP & !QC_ARP_D0177 707 725 if (pcCU->getMergeFlag(0) && pcCU->getMergeIndex(0)==0 && pcCU->getResPredAvail(0)) 708 726 { -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecCu.h
r296 r373 61 61 TComYuv** m_ppcYuvResi; ///< array of residual buffer 62 62 TComYuv** m_ppcYuvReco; ///< array of prediction & reconstruction buffer 63 #if H3D_IVRP 63 #if H3D_IVRP & !QC_ARP_D0177 64 64 TComYuv** m_ppcYuvResPred; ///< residual prediction buffer 65 65 #endif -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecEntropy.cpp
r332 r373 108 108 } 109 109 110 #if QC_ARP_D0177 111 Void TDecEntropy::decodeARPW( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, TComDataCU* pcSubCU, UInt uiPUIdx ) 112 { 113 if( pcCU->getSlice()->getViewId() == 0 || pcCU->getSlice()->getIsDepth() == true || !pcCU->getSlice()->getARPStepNum() ) 114 return; 115 assert( !pcCU->isIntra( uiAbsPartIdx ) ); 116 Bool bResPredAvailable = !pcCU->getSlice()->getARPStepNum() ? false: ((pcCU->getPartitionSize(uiAbsPartIdx)==SIZE_2Nx2N || pcCU->isSkipped(uiAbsPartIdx)) ? true: false); 117 if(!bResPredAvailable) 118 pcCU->setARPWSubParts( 0 , uiAbsPartIdx, uiDepth ); 119 else 120 m_pcEntropyDecoderIf->parseARPW( pcCU , uiAbsPartIdx , uiDepth ); 121 } 122 #endif 110 123 Void TDecEntropy::decodeSplitFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 111 124 { … … 189 202 { 190 203 decodePUWise( pcCU, uiAbsPartIdx, uiDepth, pcSubCU ); 204 #if QC_ARP_D0177 205 if( pcCU->getSlice()->getSPS()->getUseAdvRP() ) 206 { 207 decodeARPW( pcCU , uiAbsPartIdx , uiDepth, pcSubCU, 0 ); 208 } 209 #endif 191 210 } 192 211 } -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecEntropy.h
r332 r373 106 106 virtual Void parseResPredFlag ( TComDataCU* pcCU, Bool& rbResPredFlag, UInt uiAbsPartIdx, UInt uiDepth ) = 0; 107 107 #endif 108 #if QC_ARP_D0177 109 virtual Void parseARPW ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) = 0; 110 #endif 108 111 virtual Void parsePartSize ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) = 0; 109 112 virtual Void parsePredMode ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) = 0; … … 198 201 Void decodeMergeFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPUIdx ); 199 202 Void decodeMergeIndex ( TComDataCU* pcSubCU, UInt uiPartIdx, UInt uiPartAddr, PartSize eCUMode, UChar* puhInterDirNeighbours, TComMvField* pcMvFieldNeighbours, UInt uiDepth ); 203 #if QC_ARP_D0177 204 Void decodeARPW ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, TComDataCU* pcSubCU, UInt uiPUIdx ); 205 #endif 200 206 Void decodePredMode ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 201 207 Void decodePartSize ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecGop.cpp
r296 r373 93 93 ,TComDepthMapGenerator* pcDepthMapGenerator 94 94 #endif 95 #if H3D_IVRP 95 #if H3D_IVRP & !QC_ARP_D0177 96 96 ,TComResidualGenerator* pcResidualGenerator 97 97 #endif … … 109 109 m_pcDepthMapGenerator = pcDepthMapGenerator; 110 110 #endif 111 #if H3D_IVRP 111 #if H3D_IVRP & !QC_ARP_D0177 112 112 m_pcResidualGenerator = pcResidualGenerator; 113 113 #endif … … 298 298 m_pcDepthMapGenerator->predictDepthMap ( rpcPic ); 299 299 #endif 300 #if H3D_IVRP 300 #if H3D_IVRP & !QC_ARP_D0177 301 301 m_pcResidualGenerator->initViewComponent( rpcPic ); 302 302 #endif … … 331 331 else 332 332 { 333 #if H3D_IVRP 333 #if H3D_IVRP & !QC_ARP_D0177 334 334 // set residual picture 335 335 m_pcResidualGenerator->setRecResidualPic( rpcPic ); -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecGop.h
r296 r373 90 90 TComDepthMapGenerator* m_pcDepthMapGenerator; 91 91 #endif 92 #if H3D_IVRP 92 #if H3D_IVRP & !QC_ARP_D0177 93 93 TComResidualGenerator* m_pcResidualGenerator; 94 94 #endif … … 118 118 ,TComDepthMapGenerator* pcDepthMapGenerator 119 119 #endif 120 #if H3D_IVRP 120 #if H3D_IVRP & !QC_ARP_D0177 121 121 ,TComResidualGenerator* pcResidualGenerator 122 122 #endif -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecSbac.cpp
r332 r373 64 64 #if H3D_IVRP 65 65 , m_cResPredFlagSCModel ( 1, 1, NUM_RES_PRED_FLAG_CTX , m_contextModels + m_numContextModels, m_numContextModels) 66 #endif 67 #if QC_ARP_D0177 68 , m_cCUPUARPW ( 1, 1, NUM_ARPW_CTX , m_contextModels + m_numContextModels, m_numContextModels) 66 69 #endif 67 70 , m_cCUPartSizeSCModel ( 1, 1, NUM_PART_SIZE_CTX , m_contextModels + m_numContextModels, m_numContextModels) … … 162 165 m_cResPredFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_RES_PRED_FLAG ); 163 166 #endif 167 #if QC_ARP_D0177 168 m_cCUPUARPW.initBuffer ( sliceType, qp, (UChar*)INIT_ARPW ); 169 #endif 164 170 m_cCUAlfCtrlFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_ALF_CTRL_FLAG ); 165 171 m_cCUPartSizeSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_PART_SIZE ); … … 248 254 #if H3D_IVRP 249 255 m_cResPredFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_RES_PRED_FLAG ); 256 #endif 257 #if QC_ARP_D0177 258 m_cCUPUARPW.initBuffer ( eSliceType, iQp, (UChar*)INIT_ARPW ); 250 259 #endif 251 260 m_cCUAlfCtrlFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_ALF_CTRL_FLAG ); … … 2235 2244 } 2236 2245 #endif 2237 2246 #if QC_ARP_D0177 2247 Void TDecSbac::parseARPW( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 2248 { 2249 UInt nMaxW = pcCU->getSlice()->getARPStepNum() - 1; 2250 assert (nMaxW >= 0); 2251 UInt nW = 0; 2252 if( nMaxW > 0 ) 2253 { 2254 UInt nOffset = pcCU->getCTXARPWFlag(uiAbsPartIdx); 2255 assert( 0 <= nOffset && nOffset <= 2 ); 2256 UInt uiCode = 0; 2257 m_pcTDecBinIf->decodeBin( uiCode , m_cCUPUARPW.get( 0, 0, 0 + nOffset ) ); 2258 nW = uiCode; 2259 if( nW == 1 ) 2260 { 2261 m_pcTDecBinIf->decodeBin( uiCode , m_cCUPUARPW.get( 0, 0, 3 ) ); 2262 nW += ( uiCode == 1 ); 2263 } 2264 } 2265 pcCU->setARPWSubParts( ( UChar )( nW ) , uiAbsPartIdx, uiDepth ); 2266 } 2267 #endif 2238 2268 #if LGE_EDGE_INTRA_A0070 2239 2269 Void TDecSbac::xParseEdgeIntraInfo( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecSbac.h
r332 r373 176 176 Void parseResPredFlag ( TComDataCU* pcCU, Bool& rbResPredFlag, UInt uiAbsPartIdx, UInt uiDepth ); 177 177 #endif 178 #if QC_ARP_D0177 179 Void parseARPW ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 180 #endif 178 181 Void parsePartSize ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 179 182 Void parsePredMode ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); … … 218 221 #if H3D_IVRP 219 222 ContextModel3DBuffer m_cResPredFlagSCModel; 223 #endif 224 #if QC_ARP_D0177 225 ContextModel3DBuffer m_cCUPUARPW; 220 226 #endif 221 227 ContextModel3DBuffer m_cCUPartSizeSCModel; -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecTop.cpp
r332 r373 403 403 m_cDepthMapGenerator.destroy(); 404 404 #endif 405 #if H3D_IVRP 405 #if H3D_IVRP & !QC_ARP_D0177 406 406 m_cResidualGenerator.destroy(); 407 407 #endif … … 420 420 , &m_cDepthMapGenerator 421 421 #endif 422 #if H3D_IVRP 422 #if H3D_IVRP & !QC_ARP_D0177 423 423 , &m_cResidualGenerator 424 424 #endif … … 434 434 #endif 435 435 #endif 436 #if H3D_IVRP 436 #if H3D_IVRP & !QC_ARP_D0177 437 437 m_cResidualGenerator.init( &m_cTrQuant, &m_cDepthMapGenerator ); 438 438 #endif … … 860 860 } 861 861 #endif 862 #if H3D_IVRP 862 #if H3D_IVRP & !QC_ARP_D0177 863 863 m_cResidualGenerator.create( true, m_apcSlicePilot->getSPS()->getPicWidthInLumaSamples(), m_apcSlicePilot->getSPS()->getPicHeightInLumaSamples(), g_uiMaxCUDepth, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiBitDepth + g_uiBitIncrement ); 864 864 #endif … … 1083 1083 std::vector<TComPic*> apcInterViewRefPics = m_tAppDecTop->getInterViewRefPics( m_viewId, pcSlice->getPOC(), m_isDepth, pcSlice->getSPS() ); 1084 1084 pcSlice->setRefPicListMvc( m_cListPic, apcInterViewRefPics ); 1085 1085 #if QC_ARP_D0177 1086 //pcSlice->setBaseViewRefPicList( m_tAppDecTop->getTDecTop( 0 , false )->getListPic() ); 1087 pcSlice->setARPStepNum(); 1088 if(pcSlice->getARPStepNum() > 1) 1089 { 1090 for(Int iViewIdx = 0; iViewIdx < pcSlice->getViewId(); iViewIdx ++ ) 1091 pcSlice->setBaseViewRefPicList( m_tAppDecTop->getTDecTop( iViewIdx, false )->getListPic(), iViewIdx ); 1092 } 1093 #endif 1086 1094 // For generalized B 1087 1095 // note: maybe not existed case (always L0 is copied to L1 if L1 is empty) -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibDecoder/TDecTop.h
r296 r373 213 213 TComDepthMapGenerator m_cDepthMapGenerator; 214 214 #endif 215 #if H3D_IVRP 215 #if H3D_IVRP & !QC_ARP_D0177 216 216 TComResidualGenerator m_cResidualGenerator; 217 217 #endif -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncCavlc.cpp
r332 r373 711 711 WRITE_UVLC( pcSPS->getMultiviewMvPredMode(), "multi_view_mv_pred_mode" ); 712 712 #endif 713 #if H3D_IVRP 713 #if H3D_IVRP & !QC_ARP_D0177 714 714 WRITE_FLAG ( pcSPS->getMultiviewResPredMode(), "multi_view_residual_pred_mode" ); 715 715 #endif 716 716 } 717 #endif 718 #if QC_ARP_D0177 719 WRITE_FLAG( pcSPS->getUseAdvRP () ? 1 : 0, "advanced_residual_pred_flag" ); 717 720 #endif 718 721 } … … 1321 1324 } 1322 1325 #endif 1323 1326 #if QC_ARP_D0177 1327 Void TEncCavlc::codeARPW( TComDataCU* pcCU, UInt uiAbsPartIdx ) 1328 { 1329 assert( false ); 1330 } 1331 #endif 1324 1332 Void TEncCavlc::codeAlfCtrlFlag( TComDataCU* pcCU, UInt uiAbsPartIdx ) 1325 1333 { -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncCavlc.h
r332 r373 160 160 Void codeResPredFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx ); 161 161 #endif 162 #if QC_ARP_D0177 163 virtual Void codeARPW ( TComDataCU* pcCU, UInt uiAbsPartIdx ); 164 #endif 162 165 Void codeAlfCtrlFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx ); 163 166 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncCfg.h
r332 r373 333 333 #endif 334 334 #if H3D_IVRP 335 #if QC_ARP_D0177 336 UInt m_nUseAdvResPred; 337 UInt m_nARPStepNum; 338 #else 335 339 UInt m_uiMultiviewResPredMode; 340 #endif 336 341 #endif 337 342 … … 414 419 #endif 415 420 #if H3D_IVRP 421 #if QC_ARP_D0177 422 UInt getUseAdvRP () { return m_nUseAdvResPred; } 423 Void setUseAdvRP ( UInt u ) { m_nUseAdvResPred = u; } 424 UInt getARPStepNum () { return m_nARPStepNum; } 425 Void setARPStepNum ( UInt u ) { m_nARPStepNum = u; } 426 #else 416 427 Void setMultiviewResPredMode ( UInt u ) { m_uiMultiviewResPredMode = u; } 428 #endif 417 429 #endif 418 430 … … 809 821 Int getViewOrderIdx () { return m_iViewOrderIdx; } // will be changed to view_id 810 822 #endif 823 811 824 }; 812 825 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncCu.cpp
r351 r373 64 64 m_ppcBestCU = new TComDataCU*[m_uhTotalDepth-1]; 65 65 m_ppcTempCU = new TComDataCU*[m_uhTotalDepth-1]; 66 66 #if QC_ARP_D0177 67 m_ppcWeightedTempCU = new TComDataCU*[m_uhTotalDepth-1]; 68 #endif 67 69 m_ppcPredYuvBest = new TComYuv*[m_uhTotalDepth-1]; 68 70 m_ppcResiYuvBest = new TComYuv*[m_uhTotalDepth-1]; … … 91 93 m_ppcBestCU[i] = new TComDataCU; m_ppcBestCU[i]->create( uiNumPartitions, uiWidth, uiHeight, false, uiMaxWidth >> (m_uhTotalDepth - 1) ); 92 94 m_ppcTempCU[i] = new TComDataCU; m_ppcTempCU[i]->create( uiNumPartitions, uiWidth, uiHeight, false, uiMaxWidth >> (m_uhTotalDepth - 1) ); 93 95 #if QC_ARP_D0177 96 m_ppcWeightedTempCU[i] = new TComDataCU; m_ppcWeightedTempCU[i]->create( uiNumPartitions, uiWidth, uiHeight, false, uiMaxWidth >> (m_uhTotalDepth - 1) ); 97 #endif 94 98 m_ppcPredYuvBest[i] = new TComYuv; m_ppcPredYuvBest[i]->create(uiWidth, uiHeight); 95 99 m_ppcResiYuvBest[i] = new TComYuv; m_ppcResiYuvBest[i]->create(uiWidth, uiHeight); … … 170 174 { 171 175 m_ppcResPredTmp [i]->destroy(); delete m_ppcResPredTmp[i]; m_ppcResPredTmp[i] = NULL; 176 } 177 #endif 178 #if QC_ARP_D0177 179 if(m_ppcWeightedTempCU[i]) 180 { 181 m_ppcWeightedTempCU[i]->destroy(); delete m_ppcWeightedTempCU[i]; m_ppcWeightedTempCU[i] = NULL; 172 182 } 173 183 #endif … … 596 606 if( rpcTempCU->getSlice()->getSliceType() != I_SLICE ) 597 607 { 608 #if QC_ARP_D0177 609 if(( rpcTempCU->getSlice()->getSPS()->getMultiviewMvPredMode() || rpcTempCU->getSlice()->getSPS()->getUseAdvRP()) && rpcTempCU->getSlice()->getViewId()) 610 #else 598 611 if(( rpcTempCU->getSlice()->getSPS()->getMultiviewMvPredMode() || rpcTempCU->getSlice()->getSPS()->getMultiviewResPredMode()) && rpcTempCU->getSlice()->getViewId()) 612 #endif 599 613 { 600 614 PartSize ePartTemp = rpcTempCU->getPartitionSize(0); … … 624 638 { 625 639 #if H3D_IVRP 640 #if QC_ARP_D0177 641 Bool bResPredAvailable = false; 642 Bool bResPredAllowed = (!rpcBestCU->getSlice()->getSPS()->isDepth () ); 643 bResPredAllowed = bResPredAllowed && ( rpcBestCU->getSlice()->getSPS()->getViewId () ); 644 if( bResPredAllowed ) 645 { 646 bResPredAvailable = rpcBestCU->getResidualSamples( 0, true, m_ppcResPredTmp[uiDepth] ); 647 } 648 for( UInt uiResPrdId = 0; uiResPrdId < (rpcBestCU->getSlice()->getSPS()->getUseAdvRP()? 1: ( bResPredAvailable ? 2 : 1 )); uiResPrdId++ ) 649 #else 626 650 Bool bResPredAvailable = false; 627 651 UInt uiResPrdId = 0; 652 #endif 628 653 { 629 654 Bool bResPredFlag = ( uiResPrdId > 0 ); … … 743 768 { 744 769 #if H3D_IVRP 770 #if QC_ARP_D0177 771 Bool bResPredAvailable = false; 772 Bool bResPredAllowed = (!rpcBestCU->getSlice()->getSPS()->isDepth () ); 773 bResPredAllowed = bResPredAllowed && ( rpcBestCU->getSlice()->getSPS()->getViewId () ); 774 if( bResPredAllowed ) 775 { 776 bResPredAvailable = rpcBestCU->getResidualSamples( 0, true, m_ppcResPredTmp[uiDepth] ); 777 } 778 for( UInt uiResPrdId = 0; uiResPrdId < (rpcBestCU->getSlice()->getSPS()->getUseAdvRP()? 1: ( bResPredAvailable ? 2 : 1 )); uiResPrdId++ ) 779 #else 745 780 Bool bResPredAvailable = false; 746 781 UInt uiResPrdId = 0; 782 #endif 747 783 { 748 784 Bool bResPredFlag = ( uiResPrdId > 0 ); … … 1795 1831 ); 1796 1832 #endif 1833 #if QC_ARP_D0177 1834 m_pcEntropyCoder->encodeARPW( pcCU , uiAbsPartIdx, 0, uiDepth); 1835 #endif 1797 1836 finishCU(pcCU,uiAbsPartIdx,uiDepth); 1798 1837 return; … … 1861 1900 Int numValidMergeCand = 0; 1862 1901 1902 #if QC_ARP_D0177 1903 Bool bResPrdAvail = rpcTempCU->getResPredAvail( 0 ); 1904 Bool bResPrdFlag = rpcTempCU->getResPredFlag ( 0 ); 1905 #endif 1863 1906 #if LGE_ILLUCOMP_B0045 1864 1907 Bool bICFlag = rpcTempCU->getICFlag(0); … … 1893 1936 rpcTempCU->getInterMergeCandidates( 0, 0, uhDepth, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand ); 1894 1937 #endif 1895 #if H3D_IVRP 1938 #if H3D_IVRP & !QC_ARP_D0177 1896 1939 Bool bResPredAvail = rpcTempCU->getResPredAvail(0); 1897 1940 #endif 1898 1941 1899 1942 Bool bestIsSkip = false; 1900 1943 #if QC_ARP_D0177 1944 Int nGRPW = rpcTempCU->getSlice()->getARPStepNum() - 1; 1945 if(nGRPW < 0 || !bResPrdAvail ) 1946 nGRPW = 0; 1947 for( ; nGRPW >= 0 ; nGRPW-- ) 1948 { 1949 #endif 1901 1950 for( UInt uiMergeCand = 0; uiMergeCand < numValidMergeCand; ++uiMergeCand ) 1902 1951 { … … 1932 1981 rpcTempCU->setPredModeSubParts( MODE_SKIP, 0, uhDepth ); // interprets depth relative to LCU level 1933 1982 rpcTempCU->setPartSizeSubParts( SIZE_2Nx2N, 0, uhDepth ); // interprets depth relative to LCU level 1983 #if QC_ARP_D0177 1984 if(rpcTempCU->getSlice()->getSPS()->getUseAdvRP()) 1985 rpcTempCU->setARPWSubParts( ( UChar )nGRPW , 0 , uhDepth ); 1986 #endif 1934 1987 rpcTempCU->setMergeFlagSubParts( true, 0, 0, uhDepth ); // interprets depth relative to LCU level 1935 1988 rpcTempCU->setMergeIndexSubParts( uiMergeCand, 0, 0, uhDepth ); // interprets depth relative to LCU level … … 1955 2008 1956 2009 #if H3D_IVRP 2010 #if !QC_ARP_D0177 1957 2011 rpcTempCU->setResPredAvailSubParts(bResPredAvail, 0, 0, uhDepth); 2012 #else 2013 rpcTempCU->setResPredAvailSubParts( bResPrdAvail, 0, 0, uhDepth ); 2014 rpcTempCU->setResPredFlagSubParts ( bResPrdFlag, 0, 0, uhDepth ); 2015 #endif 1958 2016 #endif 1959 2017 #if LGE_ILLUCOMP_B0045 1960 2018 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uhDepth); 1961 2019 #endif 1962 2020 #if QC_ARP_D0177 2021 if(rpcTempCU->getSlice()->getSPS()->getUseAdvRP()) 2022 { 2023 bool bSignalflag[2] = {true, true}; 2024 for(UInt uiRefListIdx = 0; uiRefListIdx < 2; uiRefListIdx ++ ) 2025 { 2026 Int iRefIdx = cMvFieldNeighbours[uiRefListIdx + 2*uiMergeCand].getRefIdx(); 2027 RefPicList eRefList = uiRefListIdx ? REF_PIC_LIST_1 : REF_PIC_LIST_0; 2028 if(iRefIdx < 0 || rpcTempCU->getSlice()->getPOC() == rpcTempCU->getSlice()->getRefPOC(eRefList, iRefIdx)) 2029 bSignalflag[uiRefListIdx] = false; 2030 } 2031 if(!bSignalflag[0]&& !bSignalflag[1]) 2032 { 2033 rpcTempCU->setARPWSubParts( 0 , 0 , uhDepth ); 2034 } 2035 } 2036 #endif 1963 2037 // do MC 1964 2038 #if HHI_INTERVIEW_SKIP … … 1973 2047 m_pcPredSearch->motionCompensation ( rpcTempCU, m_ppcPredYuvTemp[uhDepth] ); 1974 2048 #endif 1975 #if H3D_IVRP 2049 #if H3D_IVRP & !QC_ARP_D0177 1976 2050 if (uiMergeCand == 0 && rpcTempCU->getResPredAvail(0)) 1977 2051 { … … 1992 2066 m_pcPredSearch->motionCompensation ( rpcTempCU, m_ppcPredYuvTemp[uhDepth] ); 1993 2067 #endif 1994 #if H3D_IVRP 2068 #if H3D_IVRP & !QC_ARP_D0177 1995 2069 if (uiMergeCand == 0 && rpcTempCU->getResPredAvail(0)) 1996 2070 { … … 2049 2123 } 2050 2124 } 2125 #if QC_ARP_D0177 2126 } 2127 #endif 2051 2128 } 2052 2129 … … 2066 2143 { 2067 2144 UChar uhDepth = rpcTempCU->getDepth( 0 ); 2068 2145 #if QC_ARP_D0177 2146 Bool bFirstTime = true; 2147 Int nARPWMax = rpcTempCU->getSlice()->getARPStepNum() - 1; 2148 if(nARPWMax < 0 || !rpcTempCU->getResPredAvail( 0 ) ) 2149 nARPWMax = 0; 2150 if( ePartSize != SIZE_2Nx2N) 2151 nARPWMax = 0; 2152 Int nARPWStart = 0 , nARPWStep = 1; 2153 for( Int nCount = 0 , nGRPW = nARPWStart ; nCount <= nARPWMax ; nCount++ , nGRPW += nARPWStep ) 2154 { 2155 if( bFirstTime == false && rpcTempCU->getSlice()->getSPS()->getUseAdvRP() ) 2156 rpcTempCU->initEstData( rpcTempCU->getDepth(0), rpcTempCU->getQP(0) ); 2157 #endif 2069 2158 #if HHI_VSO 2070 2159 if( m_pcRdCost->getUseRenModel() ) … … 2093 2182 rpcTempCU->setPredModeSubParts ( MODE_INTER, 0, uhDepth ); 2094 2183 2184 #if QC_ARP_D0177 2185 if(rpcTempCU->getSlice()->getSPS()->getUseAdvRP()) 2186 rpcTempCU->setARPWSubParts( ( UChar )nGRPW , 0 , uhDepth ); 2187 #endif 2188 #if QC_ARP_D0177 2189 if( bFirstTime == false && rpcTempCU->getSlice()->getSPS()->getUseAdvRP()) 2190 { 2191 assert(!rpcTempCU->getSlice()->getSPS()->isDepth()); 2192 rpcTempCU->copyPartFrom( m_ppcWeightedTempCU[uhDepth] , 0 , uhDepth, true ); 2193 rpcTempCU->setARPWSubParts( ( UChar )nGRPW , 0 , uhDepth ); 2194 #if MERL_VSP_C0152 2195 m_pcPredSearch->motionCompensation( rpcTempCU , m_ppcPredYuvTemp[uhDepth], 0); 2196 #else 2197 m_pcPredSearch->motionCompensation( rpcTempCU , m_ppcPredYuvTemp[uhDepth] ); 2198 #endif 2199 if(rpcTempCU->getPartitionSize(0)==SIZE_2Nx2N) 2200 { 2201 bool bSignalflag[2] = {true, true}; 2202 for(UInt uiRefListIdx = 0; uiRefListIdx < 2; uiRefListIdx ++ ) 2203 { 2204 RefPicList eRefList = uiRefListIdx ? REF_PIC_LIST_1 : REF_PIC_LIST_0; 2205 Int iRefIdx = rpcTempCU->getCUMvField(eRefList)->getRefIdx(0); 2206 if(iRefIdx < 0 || rpcTempCU->getSlice()->getPOC() == rpcTempCU->getSlice()->getRefPOC(eRefList, iRefIdx)) 2207 bSignalflag[uiRefListIdx] = false; 2208 } 2209 if(!bSignalflag[0]&& !bSignalflag[1]) 2210 rpcTempCU->setARPWSubParts( 0 , 0 , uhDepth ); 2211 } 2212 } 2213 else 2214 { 2215 bFirstTime = false; 2216 #endif 2095 2217 #if AMP_MRG 2096 2218 rpcTempCU->setMergeAMP (true); … … 2107 2229 #endif 2108 2230 #endif 2231 #if QC_ARP_D0177 2232 if(rpcTempCU->getSlice()->getSPS()->getUseAdvRP()) 2233 { 2234 m_ppcWeightedTempCU[uhDepth]->copyPartFrom( rpcTempCU , 0 , uhDepth ); 2235 if(rpcTempCU->getSlice()->getSPS()->getUseAdvRP() && rpcTempCU->getPartitionSize(0)==SIZE_2Nx2N) 2236 { 2237 bool bSignalflag[2] = {true, true}; 2238 for(UInt uiRefListIdx = 0; uiRefListIdx < 2; uiRefListIdx ++ ) 2239 { 2240 RefPicList eRefList = uiRefListIdx ? REF_PIC_LIST_1 : REF_PIC_LIST_0; 2241 Int iRefIdx = rpcTempCU->getCUMvField(eRefList)->getRefIdx(0); 2242 if(iRefIdx < 0 || rpcTempCU->getSlice()->getPOC() == rpcTempCU->getSlice()->getRefPOC(eRefList, iRefIdx)) 2243 bSignalflag[uiRefListIdx] = false; 2244 } 2245 if(!bSignalflag[0]&& !bSignalflag[1]) 2246 rpcTempCU->setARPWSubParts( 0 , 0 , uhDepth ); 2247 } 2248 } 2249 } 2250 #endif 2109 2251 2110 2252 #if AMP_MRG 2111 2253 if ( !rpcTempCU->getMergeAMP() ) 2112 2254 { 2255 #if QC_ARP_D0177 2256 if(rpcTempCU->getSlice()->getSPS()->getUseAdvRP()) 2257 continue; 2258 else 2259 #endif 2113 2260 return; 2114 2261 } … … 2151 2298 xCheckDQP( rpcTempCU ); 2152 2299 xCheckBestMode(rpcBestCU, rpcTempCU, uhDepth); 2300 #if QC_ARP_D0177 2301 } 2302 #endif 2153 2303 } 2154 2304 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncCu.h
r296 r373 69 69 TComDataCU** m_ppcBestCU; ///< Best CUs in each depth 70 70 TComDataCU** m_ppcTempCU; ///< Temporary CUs in each depth 71 #if QC_ARP_D0177 72 TComDataCU** m_ppcWeightedTempCU; 73 #endif 71 74 UChar m_uhTotalDepth; 72 75 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncEntropy.cpp
r332 r373 456 456 457 457 458 #if QC_ARP_D0177 459 Void TEncEntropy::encodeARPW( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD, UInt uiDepth) 460 { 461 if( pcCU->getSlice()->getViewId() == 0 || pcCU->getSlice()->getIsDepth() == true || !pcCU->getSlice()->getARPStepNum() ) 462 { 463 return; 464 } 465 assert( pcCU->isIntra( uiAbsPartIdx ) == false ); 466 if( bRD ) 467 { 468 uiAbsPartIdx = 0; 469 } 470 bool bSignalflag[2] = {true, true}; 471 if (!(pcCU->getPartitionSize(uiAbsPartIdx)==SIZE_2Nx2N || pcCU->isSkipped(uiAbsPartIdx))) 472 { 473 assert(pcCU->getARPW (uiAbsPartIdx) == 0); 474 bSignalflag[0] = false; 475 bSignalflag[1] = false; 476 } 477 if (!(bSignalflag[0]|| bSignalflag[1])) 478 { 479 assert(pcCU->getARPW (uiAbsPartIdx) == 0); 480 if (uiDepth != -1) 481 pcCU->setARPWSubParts(0, uiAbsPartIdx, uiDepth); 482 } 483 else 484 m_pcEntropyCoderIf->codeARPW( pcCU, uiAbsPartIdx ); 485 486 } 487 #endif 458 488 /** parse the fixed length code (smaller than one max value) in ALF 459 489 * \param run: coded value … … 1233 1263 { 1234 1264 encodePUWise( pcCU, uiAbsPartIdx, bRD ); 1265 #if QC_ARP_D0177 1266 encodeARPW( pcCU , uiAbsPartIdx , bRD ); 1267 #endif 1235 1268 } 1236 1269 } -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncEntropy.h
r332 r373 117 117 virtual Void codeResPredFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx ) = 0; 118 118 #endif 119 #if QC_ARP_D0177 120 virtual Void codeARPW ( TComDataCU* pcCU, UInt uiAbsPartIdx ) = 0; 121 #endif 119 122 virtual Void codeSplitFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) = 0; 120 123 … … 250 253 Void encodeMergeFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiPUIdx ); 251 254 Void encodeMergeIndex ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiPUIdx, Bool bRD = false ); 255 #if QC_ARP_D0177 256 Void encodeARPW ( TComDataCU* pcCU, UInt uiAbspartIdx , Bool bRD = false, UInt uiDepth = -1); 257 #endif 252 258 Void encodeAlfCtrlFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD = false ); 253 259 -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncGOP.cpp
r332 r373 78 78 m_pcDepthMapGenerator = NULL; 79 79 #endif 80 #if H3D_IVRP 80 #if H3D_IVRP & !QC_ARP_D0177 81 81 m_pcResidualGenerator = NULL; 82 82 #endif … … 131 131 m_pcDepthMapGenerator = pcTEncTop->getDepthMapGenerator(); 132 132 #endif 133 #if H3D_IVRP 133 #if H3D_IVRP & !QC_ARP_D0177 134 134 m_pcResidualGenerator = pcTEncTop->getResidualGenerator(); 135 135 #endif … … 390 390 std::vector<TComPic*> apcInterViewRefPics = tAppEncTop->getInterViewRefPics( m_pcEncTop->getViewId(), pcSlice->getPOC(), m_pcEncTop->getIsDepth(), pcSlice->getSPS() ); 391 391 pcSlice->setRefPicListMvc( rcListPic, apcInterViewRefPics ); 392 392 #if QC_ARP_D0177 393 pcSlice->setARPStepNum(); 394 if(pcSlice->getARPStepNum() > 1) 395 { 396 for(Int iViewIdx = 0; iViewIdx < pcSlice->getViewId(); iViewIdx ++ ) 397 pcSlice->setBaseViewRefPicList( tAppEncTop->getTEncTop( iViewIdx , false )->getListPic(), iViewIdx ); 398 } 399 #endif 393 400 // Slice info. refinement 394 401 if( pcSlice->getSliceType() == B_SLICE ) … … 754 761 m_pcDepthMapGenerator->covertOrgDepthMap( pcPic ); 755 762 #endif 756 #if H3D_IVRP 763 #if H3D_IVRP & !QC_ARP_D0177 757 764 m_pcResidualGenerator->initViewComponent( pcPic ); 758 765 #endif … … 818 825 pcSlice = pcPic->getSlice(0); 819 826 820 #if H3D_IVRP 827 #if H3D_IVRP & !QC_ARP_D0177 821 828 // set residual picture 822 829 m_pcResidualGenerator->setRecResidualPic( pcPic ); -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncGOP.h
r296 r373 97 97 TComDepthMapGenerator* m_pcDepthMapGenerator; 98 98 #endif 99 #if H3D_IVRP 99 #if H3D_IVRP & !QC_ARP_D0177 100 100 TComResidualGenerator* m_pcResidualGenerator; 101 101 #endif -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncSbac.cpp
r332 r373 72 72 #if H3D_IVRP 73 73 , m_cResPredFlagSCModel ( 1, 1, NUM_RES_PRED_FLAG_CTX , m_contextModels + m_numContextModels, m_numContextModels) 74 #endif 75 #if QC_ARP_D0177 76 , m_cCUPUARPW ( 1, 1, NUM_ARPW_CTX , m_contextModels + m_numContextModels, m_numContextModels) 74 77 #endif 75 78 , m_cCUPartSizeSCModel ( 1, 1, NUM_PART_SIZE_CTX , m_contextModels + m_numContextModels, m_numContextModels) … … 158 161 m_cResPredFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_RES_PRED_FLAG ); 159 162 #endif 163 #if QC_ARP_D0177 164 m_cCUPUARPW.initBuffer ( eSliceType, iQp, (UChar*)INIT_ARPW ); 165 #endif 160 166 m_cCUPartSizeSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_PART_SIZE ); 161 167 m_cCUAMPSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_CU_AMP_POS ); … … 311 317 m_cResPredFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_RES_PRED_FLAG ); 312 318 #endif 319 #if QC_ARP_D0177 320 m_cCUPUARPW.initBuffer ( eSliceType, iQp, (UChar*)INIT_ARPW ); 321 #endif 313 322 m_cCUPartSizeSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_PART_SIZE ); 314 323 m_cCUAMPSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_CU_AMP_POS ); … … 840 849 } 841 850 #endif 842 851 #if QC_ARP_D0177 852 Void TEncSbac::codeARPW( TComDataCU* pcCU, UInt uiAbsPartIdx ) 853 { 854 Int nW = pcCU->getARPW( uiAbsPartIdx ); 855 Int nMaxW = pcCU->getSlice()->getARPStepNum() - 1; 856 assert( 0 <= nW && nW <= nMaxW ); 857 assert(nMaxW > 0); 858 if( nMaxW > 0 ) 859 { 860 Int nOffset = pcCU->getCTXARPWFlag(uiAbsPartIdx); 861 assert( 0 <= nOffset && nOffset <= 2 ); 862 Int nBinNum = nW + ( nW != nMaxW ); 863 m_pcBinIf->encodeBin( nW != 0 , m_cCUPUARPW.get( 0, 0, 0 + nOffset ) ); 864 if( nBinNum > 1 ) 865 m_pcBinIf->encodeBin( nW == nMaxW , m_cCUPUARPW.get( 0, 0, 3 ) ); 866 } 867 } 868 #endif 843 869 Void TEncSbac::codeSplitFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 844 870 { -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncSbac.h
r332 r373 209 209 Void codeResPredFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx ); 210 210 #endif 211 #if QC_ARP_D0177 212 virtual Void codeARPW ( TComDataCU* pcCU, UInt uiAbsPartIdx ); 213 #endif 211 214 Void codeSplitFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 212 215 #if H3D_IVMP … … 265 268 #if H3D_IVRP 266 269 ContextModel3DBuffer m_cResPredFlagSCModel; 270 #endif 271 #if QC_ARP_D0177 272 ContextModel3DBuffer m_cCUPUARPW; 267 273 #endif 268 274 ContextModel3DBuffer m_cCUPartSizeSCModel; -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncSearch.cpp
r332 r373 4674 4674 #endif 4675 4675 ); 4676 #if QC_ARP_D0177 4677 m_pcEntropyCoder->encodeARPW ( pcCU , 0 , true ); 4678 #endif 4676 4679 #endif 4677 4680 #if HHI_MPI … … 5954 5957 ); 5955 5958 #endif 5959 #if QC_ARP_D0177 5960 m_pcEntropyCoder->encodeARPW( pcCU , 0 , true ); 5961 #endif 5956 5962 ruiBits += m_pcEntropyCoder->getNumberOfWrittenBits(); 5957 5963 } … … 5977 5983 #endif 5978 5984 ); 5985 #if QC_ARP_D0177 5986 m_pcEntropyCoder->encodeARPW( pcCU , 0 , true ); 5987 #endif 5979 5988 #endif 5980 5989 #if HHI_MPI -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncTop.cpp
r332 r373 120 120 m_cDepthMapGenerator. create( false, getSourceWidth(), getSourceHeight(), g_uiMaxCUDepth, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiBitDepth + g_uiBitIncrement, PDM_SUB_SAMP_EXP_X(m_uiPredDepthMapGeneration), PDM_SUB_SAMP_EXP_Y(m_uiPredDepthMapGeneration) ); 121 121 #endif 122 #if H3D_IVRP 122 #if H3D_IVRP & !QC_ARP_D0177 123 123 m_cResidualGenerator. create( false, getSourceWidth(), getSourceHeight(), g_uiMaxCUDepth, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiBitDepth + g_uiBitIncrement ); 124 124 #endif … … 251 251 m_cDepthMapGenerator. destroy(); 252 252 #endif 253 #if H3D_IVRP 253 #if H3D_IVRP & !QC_ARP_D0177 254 254 m_cResidualGenerator. destroy(); 255 255 #endif … … 347 347 #endif 348 348 #endif 349 #if H3D_IVRP 349 #if H3D_IVRP & !QC_ARP_D0177 350 350 m_cResidualGenerator.init( &m_cTrQuant, &m_cDepthMapGenerator ); 351 351 #endif … … 722 722 #endif 723 723 #if H3D_IVRP 724 #if QC_ARP_D0177 725 m_cSPS.setUseAdvRP ( 0 ); 726 m_cSPS.setARPStepNum ( 1 ); 727 #else 724 728 m_cSPS.setMultiviewResPredMode ( 0 ); 725 729 #endif 730 #endif 731 726 732 } 727 733 else … … 742 748 #endif 743 749 #if H3D_IVRP 744 m_cSPS.setMultiviewResPredMode ( m_uiMultiviewResPredMode ); 750 #if QC_ARP_D0177 751 m_cSPS.setUseAdvRP ( m_viewId > 0 ? m_nUseAdvResPred : 0 ); 752 m_cSPS.setARPStepNum( m_viewId > 0 ? QC_ARP_WFNR : 1 ); 753 #else 754 m_cSPS.setMultiviewResPredMode ( m_uiMultiviewResPredMode ); 755 #endif 745 756 #endif 746 757 } … … 751 762 #endif 752 763 #if H3D_IVRP 764 #if QC_ARP_D0177 765 m_cSPS.setUseAdvRP ( 0 ); 766 m_cSPS.setARPStepNum ( 1 ); 767 #else 753 768 m_cSPS.setMultiviewResPredMode ( 0 ); 769 #endif 754 770 #endif 755 771 } -
branches/HTM-6.2-dev2-Qualcomm/source/Lib/TLibEncoder/TEncTop.h
r296 r373 103 103 TComDepthMapGenerator m_cDepthMapGenerator; ///< depth map generator 104 104 #endif 105 #if H3D_IVRP 105 #if H3D_IVRP & !QC_ARP_D0177 106 106 TComResidualGenerator m_cResidualGenerator; ///< generator for residual pictures 107 107 #endif … … 234 234 TComDepthMapGenerator* getDepthMapGenerator () { return &m_cDepthMapGenerator; } 235 235 #endif 236 #if H3D_IVRP 236 #if H3D_IVRP & !QC_ARP_D0177 237 237 TComResidualGenerator* getResidualGenerator () { return &m_cResidualGenerator; } 238 238 #endif
Note: See TracChangeset for help on using the changeset viewer.