Changeset 280 in 3DVCSoftware for branches/HTM-5.1-dev0/source
- Timestamp:
- 14 Feb 2013, 23:41:41 (12 years ago)
- Location:
- branches/HTM-5.1-dev0/source
- Files:
-
- 41 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-5.1-dev0/source/App/TAppDecoder/TAppDecTop.cpp
r231 r280 96 96 #endif 97 97 98 #if SONY_COLPIC_AVAILABILITY99 m_tDecTop[0]->setViewOrderIdx(0);100 #endif101 98 Int viewDepthId = 0; 102 99 Int previousViewDepthId = 0; -
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncCfg.cpp
r231 r280 341 341 #if LGE_ILLUCOMP_B0045 342 342 ("IlluCompEnable", m_bUseIC , true , "Use illumination compensation for inter-view prediction" ) 343 #endif 344 #if INTER_VIEW_VECTOR_SCALING_C0115 345 ("IVSEnable", m_bUseIVS , true , "Use inter-view vector scaling" ) 343 346 #endif 344 347 #if DBL_CONTROL … … 1806 1809 printf("IlluCompEnable: %d ", m_bUseIC); 1807 1810 #endif 1808 1811 #if INTER_VIEW_VECTOR_SCALING_C0115 1812 printf("IVSEnable: %d ", m_bUseIVS); 1813 #endif 1809 1814 printf("\n"); 1810 1815 -
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncCfg.h
r210 r280 172 172 Bool m_bUseIC; ///< flag for using illumination compensation for inter-view prediction 173 173 #endif 174 #if INTER_VIEW_VECTOR_SCALING_C0115 175 Bool m_bUseIVS; ///< flag for using inter-view vector scaling 176 #endif 174 177 #if SAO_UNIT_INTERLEAVING 175 178 Int m_maxNumOffsetsPerPic; ///< SAO maximun number of offset per picture -
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncTop.cpp
r231 r280 121 121 m_cVPS.setDependentFlag ( iViewIdx ? true:false, layerId ); 122 122 m_cVPS.setDependentLayer ( layerId - (m_bUsingDepthMaps ? 2:1), layerId ); 123 #if INTER_VIEW_VECTOR_SCALING_C0115 124 m_cVPS.setIVScalingFlag ( m_bUseIVS ); 125 #endif 123 126 #endif 124 127 … … 316 319 #if LGE_ILLUCOMP_B0045 317 320 m_acTEncTopList[iViewIdx]->setUseIC ( m_bUseIC ); 321 #endif 322 #if INTER_VIEW_VECTOR_SCALING_C0115 323 m_acTEncTopList[iViewIdx]->setUseIVS ( m_bUseIVS ); 318 324 #endif 319 325 #if SAO_UNIT_INTERLEAVING … … 639 645 m_acTEncDepthTopList[iViewIdx]->setUseIC ( false ); 640 646 #endif 647 #if INTER_VIEW_VECTOR_SCALING_C0115 648 m_acTEncDepthTopList[iViewIdx]->setUseIVS ( m_bUseIVS ); 649 #endif 641 650 #if SAO_UNIT_INTERLEAVING 642 651 m_acTEncDepthTopList[iViewIdx]->setMaxNumOffsetsPerPic (m_maxNumOffsetsPerPic); … … 793 802 m_cUsedPelsRenderer.init(m_iSourceWidth, m_iSourceHeight, true, 0, LOG2_DISP_PREC_LUT, true, 0, 0, 0, 0, 0, 6, 4, 1, 0, 6 ); 794 803 #endif 804 795 805 } 796 806 -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDataCU.cpp
r273 r280 3397 3397 #endif 3398 3398 3399 #if LG_RESTRICTEDRESPRED_M24766 3399 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3400 3400 Int TComDataCU::getResiPredMode(UInt uiPartAddr) 3401 3401 { … … 3753 3753 { 3754 3754 #if HHI_INTER_VIEW_MOTION_PRED 3755 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 3756 const Int extraMergeCand = ( ( getSlice()->getIsDepth() || getSlice()->getSPS()->getMultiviewMvPredMode() )? 1 : 0 ); 3757 #else 3755 3758 const Int extraMergeCand = ( getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 3759 #endif 3756 3760 #endif 3757 3761 … … 3784 3788 deriveLeftRightTopIdxGeneral( cCurPS, uiAbsPartIdx, uiPUIdx, uiPartIdxLT, uiPartIdxRT ); 3785 3789 deriveLeftBottomIdxGeneral( cCurPS, uiAbsPartIdx, uiPUIdx, uiPartIdxLB ); 3790 3791 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 3792 if( m_pcSlice->getIsDepth()) 3793 { 3794 UInt uiPartIdxCenter; 3795 xDeriveCenterIdx( cCurPS, uiPUIdx, uiPartIdxCenter ); 3796 TComDataCU *pcTextureCU = m_pcSlice->getTexturePic()->getCU( getAddr() ); 3797 if ( pcTextureCU && !pcTextureCU->isIntra( uiPartIdxCenter ) ) 3798 { 3799 abCandIsInter[iCount] = true; 3800 puhInterDirNeighbours[iCount] = pcTextureCU->getInterDir( uiPartIdxCenter ); 3801 if( ( puhInterDirNeighbours[iCount] & 1 ) == 1 ) 3802 { 3803 pcTextureCU->getMvField( pcTextureCU, uiPartIdxCenter, REF_PIC_LIST_0, pcMvFieldNeighbours[iCount<<1] ); 3804 TComMv cMvPred = pcMvFieldNeighbours[iCount<<1].getMv(); 3805 const TComMv cAdd( 1 << ( 2 - 1 ), 1 << ( 2 - 1 ) ); 3806 cMvPred+=cAdd; 3807 cMvPred>>=2; 3808 clipMv(cMvPred); 3809 pcMvFieldNeighbours[iCount<<1].setMvField(cMvPred,pcMvFieldNeighbours[iCount<<1].getRefIdx()); 3810 } 3811 if ( getSlice()->isInterB() ) 3812 { 3813 if( ( puhInterDirNeighbours[iCount] & 2 ) == 2 ) 3814 { 3815 pcTextureCU->getMvField( pcTextureCU, uiPartIdxCenter, REF_PIC_LIST_1, pcMvFieldNeighbours[(iCount<<1)+1] ); 3816 TComMv cMvPred = pcMvFieldNeighbours[(iCount<<1)+1].getMv(); 3817 const TComMv cAdd( 1 << ( 2 - 1 ), 1 << ( 2 - 1 ) ); 3818 cMvPred+=cAdd; 3819 cMvPred>>=2; 3820 clipMv(cMvPred); 3821 pcMvFieldNeighbours[(iCount<<1)+1].setMvField(cMvPred,pcMvFieldNeighbours[(iCount<<1)+1].getRefIdx()); 3822 } 3823 } 3824 #if SIMP_MRG_PRUN 3825 if ( mrgCandIdx == iCount ) 3826 { 3827 return; 3828 } 3829 #endif 3830 iCount ++; 3831 } 3832 } 3833 #endif 3786 3834 3787 3835 #if HHI_INTER_VIEW_MOTION_PRED … … 3809 3857 #endif 3810 3858 3859 #if MTK_MDIVRP_C0138 3860 Bool bDVAvail = true; 3861 #endif 3862 3811 3863 #if QC_MULTI_DIS_CAN_A0097 3812 3864 DisInfo cDisInfo; … … 3837 3889 cDisInfo.m_acMvCand[0].setVer(0); 3838 3890 cDisInfo.m_aVIdxCan[0] = 0; 3891 #if MTK_MDIVRP_C0138 3892 bDVAvail = false; 3893 #endif 3839 3894 } 3840 3895 #if QC_MRG_CANS_B0048 3841 3896 Int iPdmDir[2] = {0, 0}; 3842 3897 #endif 3898 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 3899 getUnifiedMvPredCan(uiPUIdx, REF_PIC_LIST_0, 0, aiPdmRefIdx, acPdmMv, &cDisInfo, iPdmDir, true); 3900 Int iPdmInterDir; 3901 #else 3843 3902 Int iPdmInterDir = cDisInfo.iN==0? 0:getPdmMergeCandidateDisCan ( uiPUIdx, aiPdmRefIdx, acPdmMv, &cDisInfo 3844 3903 #if QC_MRG_CANS_B0048 … … 3846 3905 #endif 3847 3906 ); 3907 #endif 3848 3908 #else 3849 3909 Int iPdmInterDir = getPdmMergeCandidate( uiPUIdx, aiPdmRefIdx, acPdmMv ); 3910 #endif 3911 #if MTK_MDIVRP_C0138 3912 if (m_pcSlice->getSPS()->getMultiviewResPredMode()==1 && iPdmDir[0] && !bNoPdmMerge && cCurPS == SIZE_2Nx2N && bDVAvail) 3913 { 3914 setResPredAvailSubParts(true, 0, 0, uiDepth); 3915 } 3850 3916 #endif 3851 3917 … … 4645 4711 UInt uiCurLCUIdx = getAddr(); 4646 4712 xDeriveCenterIdx( eCUMode, uiPUIdx, uiPartIdxCenter ); 4647 bExistMV = uiLCUIdx >= 0 && xGetColMVP( REF_PIC_LIST_0, uiLCUIdx, uiAbsPartAddr, cColMv, iRefIdx ); 4713 bExistMV = uiLCUIdx >= 0 && xGetColMVP( REF_PIC_LIST_0, uiLCUIdx, uiAbsPartAddr, cColMv, iRefIdx 4714 #if QC_TMVP_MRG_REFIDX_C0047 4715 , 1 4716 #endif 4717 ); 4648 4718 if( bExistMV == false ) 4649 4719 { 4650 bExistMV = xGetColMVP( REF_PIC_LIST_0, uiCurLCUIdx, uiPartIdxCenter, cColMv, iRefIdx ); 4720 bExistMV = xGetColMVP( REF_PIC_LIST_0, uiCurLCUIdx, uiPartIdxCenter, cColMv, iRefIdx 4721 #if QC_TMVP_MRG_REFIDX_C0047 4722 , 1 4723 #endif 4724 ); 4651 4725 } 4652 4726 if( bExistMV ) … … 4663 4737 iRefIdx = 0; 4664 4738 #endif 4665 bExistMV = uiLCUIdx >= 0 && xGetColMVP( REF_PIC_LIST_1, uiLCUIdx, uiAbsPartAddr, cColMv, iRefIdx); 4739 bExistMV = uiLCUIdx >= 0 && xGetColMVP( REF_PIC_LIST_1, uiLCUIdx, uiAbsPartAddr, cColMv, iRefIdx 4740 #if QC_TMVP_MRG_REFIDX_C0047 4741 , 1 4742 #endif 4743 ); 4666 4744 if( bExistMV == false ) 4667 4745 { 4668 bExistMV = xGetColMVP( REF_PIC_LIST_1, uiCurLCUIdx, uiPartIdxCenter, cColMv, iRefIdx ); 4746 bExistMV = xGetColMVP( REF_PIC_LIST_1, uiCurLCUIdx, uiPartIdxCenter, cColMv, iRefIdx 4747 #if QC_TMVP_MRG_REFIDX_C0047 4748 , 1 4749 #endif 4750 ); 4669 4751 } 4670 4752 if( bExistMV ) … … 6895 6977 cDisInfo.m_aVIdxCan[0] = 0; 6896 6978 } 6979 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 6980 Int paiPdmRefIdx[4] = {-1, -1, -1, -1}; 6981 Int iPdmDir[4] = {-1, -1, -1, -1}; 6982 #if QC_C0051_FIXED_BY_MTK 6983 TComMv cPdmMvPred[4]; 6984 #else 6985 TComMv cPdmMvPred[2]; 6986 #endif 6987 cPdmMvPred[0].m_bDvMcp = cPdmMvPred[1].m_bDvMcp = false; 6988 if(getUnifiedMvPredCan(uiPartIdx, eRefPicList, iRefIdx, paiPdmRefIdx, cPdmMvPred, &cDisInfo, iPdmDir, false)) 6989 #else 6897 6990 TComMv cPdmMvPred; 6898 6991 #if QC_MULTI_DIS_CAN_A0097 … … 6901 6994 if( getPdmMvPred( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred ) ) 6902 6995 #endif 6996 #endif 6997 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 6998 { 6999 clipMv( cPdmMvPred[0] ); 7000 pInfo->m_acMvCand[0] = cPdmMvPred[0]; 7001 } 7002 else 7003 { 7004 pInfo->m_acMvCand[0].set(0,0); 7005 } 7006 #else 6903 7007 { 6904 7008 clipMv( cPdmMvPred ); … … 6909 7013 pInfo->m_acMvCand[0].set(0,0); 6910 7014 } 7015 #endif 6911 7016 } 6912 7017 } … … 7575 7680 Int iNeibPOC = iCurrPOC; 7576 7681 Int iNeibRefPOC; 7577 7682 #if INTER_VIEW_VECTOR_SCALING_C0116 7683 Int iCurrViewId = m_pcSlice->getViewOrderIdx(); // will be changed to view_id 7684 Int iCurrRefViewId = m_pcSlice->getRefPic(eRefPicList, iRefIdx)->getViewOrderIdx(); // will be changed to view_id 7685 Int iNeibViewId = iCurrViewId; 7686 Int iNeibRefViewId; 7687 #endif 7578 7688 #if QC_IV_AS_LT_B0046 7579 7689 Bool bIsCurrRefLongTerm = m_pcSlice->getRefPic( eRefPicList, iRefIdx)->getIsLongTerm(); … … 7583 7693 { 7584 7694 iNeibRefPOC = pcTmpCU->getSlice()->getRefPOC( eRefPicList2nd, pcTmpCU->getCUMvField(eRefPicList2nd)->getRefIdx(uiIdx) ); 7695 #if INTER_VIEW_VECTOR_SCALING_C0116 7696 iNeibRefViewId = pcTmpCU->getSlice()->getRefPic(eRefPicList2nd, pcTmpCU->getCUMvField(eRefPicList2nd)->getRefIdx(uiIdx))->getViewOrderIdx(); // will be changed to view_id 7697 #endif 7585 7698 #if QC_IV_AS_LT_B0046 7586 7699 bIsNeibRefLongTerm = m_pcSlice->getRefPic( eRefPicList2nd, pcTmpCU->getCUMvField(eRefPicList2nd)->getRefIdx(uiIdx))->getIsLongTerm() ; 7700 #if INTER_VIEW_VECTOR_SCALING_C0116 7701 if ( (bIsCurrRefLongTerm == bIsNeibRefLongTerm) && ((iNeibRefPOC == iCurrRefPOC) && (iNeibRefViewId == iCurrRefViewId))) 7702 #else 7587 7703 if ( (bIsCurrRefLongTerm == bIsNeibRefLongTerm) && (iNeibRefPOC == iCurrRefPOC) ) 7704 #endif 7588 7705 #else 7589 7706 if( pcTmpCU->getSlice()->getRefViewId( eRefPicList2nd, pcTmpCU->getCUMvField(eRefPicList2nd)->getRefIdx(uiIdx) ) != m_pcSlice->getRefViewId( eRefPicList, iRefIdx ) ) … … 7606 7723 { 7607 7724 iNeibRefPOC = pcTmpCU->getSlice()->getRefPOC( eRefPicList, pcTmpCU->getCUMvField(eRefPicList)->getRefIdx(uiIdx) ); 7725 #if INTER_VIEW_VECTOR_SCALING_C0116 7726 iNeibRefViewId = pcTmpCU->getSlice()->getRefPic(eRefPicList, pcTmpCU->getCUMvField(eRefPicList)->getRefIdx(uiIdx))->getViewOrderIdx(); // will be changed to view_id 7727 #endif 7608 7728 TComMv cMvPred = pcTmpCU->getCUMvField(eRefPicList)->getMv(uiIdx); 7609 7729 TComMv rcMv; … … 7618 7738 } 7619 7739 #endif 7740 #if INTER_VIEW_VECTOR_SCALING_C0116 7741 Int iScale = 4096; 7742 if((iCurrRefPOC != iNeibRefPOC) ) // inter & inter 7743 iScale = xGetDistScaleFactor( iCurrPOC, iCurrRefPOC, iNeibPOC, iNeibRefPOC ); 7744 else if(m_pcSlice->getIVScalingFlag()) // inter-view & inter-view 7745 iScale = xGetDistScaleFactor( iCurrViewId, iCurrRefViewId, iNeibViewId, iNeibRefViewId ); 7746 #else 7620 7747 Int iScale = xGetDistScaleFactor( iCurrPOC, iCurrRefPOC, iNeibPOC, iNeibRefPOC ); 7748 #endif 7621 7749 if ( iScale == 4096 ) 7622 7750 { … … 7640 7768 { 7641 7769 iNeibRefPOC = pcTmpCU->getSlice()->getRefPOC( eRefPicList2nd, pcTmpCU->getCUMvField(eRefPicList2nd)->getRefIdx(uiIdx) ); 7770 #if INTER_VIEW_VECTOR_SCALING_C0116 7771 iNeibRefViewId = pcTmpCU->getSlice()->getRefPic(eRefPicList2nd, pcTmpCU->getCUMvField(eRefPicList2nd)->getRefIdx(uiIdx))->getViewOrderIdx(); // will be changed to view_id 7772 #endif 7642 7773 TComMv cMvPred = pcTmpCU->getCUMvField(eRefPicList2nd)->getMv(uiIdx); 7643 7774 TComMv rcMv; … … 7652 7783 } 7653 7784 #endif 7785 #if INTER_VIEW_VECTOR_SCALING_C0116 7786 Int iScale = 4096; 7787 if((iCurrRefPOC != iNeibRefPOC)) // inter & inter 7788 iScale = xGetDistScaleFactor( iCurrPOC, iCurrRefPOC, iNeibPOC, iNeibRefPOC ); 7789 else if(m_pcSlice->getIVScalingFlag()) // inter-view & inter-view 7790 iScale = xGetDistScaleFactor( iCurrViewId, iCurrRefViewId, iNeibViewId, iNeibRefViewId ); 7791 #else 7654 7792 Int iScale = xGetDistScaleFactor( iCurrPOC, iCurrRefPOC, iNeibPOC, iNeibRefPOC ); 7793 #endif 7655 7794 if ( iScale == 4096 ) 7656 7795 { … … 7782 7921 * \returns Bool 7783 7922 */ 7784 Bool TComDataCU::xGetColMVP( RefPicList eRefPicList, Int uiCUAddr, Int uiPartUnitIdx, TComMv& rcMv, Int& riRefIdx ) 7923 Bool TComDataCU::xGetColMVP( RefPicList eRefPicList, Int uiCUAddr, Int uiPartUnitIdx, TComMv& rcMv, Int& riRefIdx 7924 #if QC_TMVP_MRG_REFIDX_C0047 7925 , 7926 Bool bMRG 7927 #endif 7928 ) 7785 7929 { 7786 7930 UInt uiAbsPartAddr = uiPartUnitIdx; … … 7788 7932 RefPicList eColRefPicList; 7789 7933 Int iColPOC, iColRefPOC, iCurrPOC, iCurrRefPOC, iScale; 7790 #if SONY_COLPIC_AVAILABILITY7791 #if QC_IV_AS_LT_B00467792 Int iColViewOrderIdx, iCurrViewOrderIdx, iCurrRefViewOrderIdx;7793 #else7794 Int iColViewOrderIdx, iColRefViewOrderIdx, iCurrViewOrderIdx, iCurrRefViewOrderIdx;7795 #endif7796 #endif7797 7934 TComMv cColMv; 7798 7799 #if SONY_COLPIC_AVAILABILITY 7800 iCurrViewOrderIdx = m_pcSlice->getViewOrderIdx(); 7801 iCurrRefViewOrderIdx = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getViewOrderIdx(); 7802 #endif 7935 #if INTER_VIEW_VECTOR_SCALING_C0115 7936 Int iColViewId, iColRefViewId, iCurrViewId, iCurrRefViewId; 7937 #endif 7938 7803 7939 // use coldir. 7804 7940 #if COLLOCATED_REF_IDX … … 7815 7951 iCurrRefPOC = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getPOC(); 7816 7952 iColPOC = pColCU->getSlice()->getPOC(); 7817 #if SONY_COLPIC_AVAILABILITY 7818 iColViewOrderIdx = pColCU->getSlice()->getViewOrderIdx(); 7953 #if INTER_VIEW_VECTOR_SCALING_C0115 7954 iCurrViewId = m_pcSlice->getViewOrderIdx(); // will be changed to view_id 7955 iCurrRefViewId = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getViewOrderIdx(); // will be changed to view_id 7956 iColViewId = pColCU->getSlice()->getViewOrderIdx(); // will be changed to view_id 7819 7957 #endif 7820 7958 … … 7824 7962 } 7825 7963 7826 #if ! SONY_COLPIC_AVAILABILITY&!QC_IV_AS_LT_B00467964 #if !INTER_VIEW_VECTOR_SCALING_C0115&!QC_IV_AS_LT_B0046 7827 7965 if( m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getViewId() != m_pcSlice->getViewId() ) 7828 7966 return false; … … 7851 7989 // Scale the vector. 7852 7990 iColRefPOC = pColCU->getSlice()->getRefPOC(eColRefPicList, iColRefIdx); 7853 7991 #if INTER_VIEW_VECTOR_SCALING_C0115 7992 iColRefViewId = pColCU->getSlice()->getRefPic( eColRefPicList, pColCU->getCUMvField(eColRefPicList)->getRefIdx(uiAbsPartAddr))->getViewOrderIdx(); // will be changed to view_id 7993 #endif 7854 7994 #if !QC_IV_AS_LT_B0046 7855 #if SONY_COLPIC_AVAILABILITY7856 iColRefViewOrderIdx = pColCU->getSlice()->getRefPic( eColRefPicList, pColCU->getCUMvField(eColRefPicList)->getRefIdx(uiAbsPartAddr))->getViewOrderIdx();7857 #else7858 7995 if( pColCU->getSlice()->getRefViewId( eColRefPicList, iColRefIdx ) != pColCU->getSlice()->getViewId() ) 7859 7996 { 7860 7997 return false; 7861 7998 } 7862 #endif7863 7999 #else 7864 8000 Bool bIsCurrRefLongTerm = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getIsLongTerm(); … … 7866 8002 if(bIsCurrRefLongTerm != bIsColRefLongTerm) 7867 8003 { 8004 #if QC_TMVP_MRG_REFIDX_C0047 8005 cColMv = pColCU->getCUMvField(eColRefPicList)->getMv(uiAbsPartAddr); 8006 iCurrRefPOC = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getPOC(); 8007 if(bMRG ) 8008 { 8009 Int iUpdRefIdx = m_pcSlice->getNewRefIdx(eRefPicList); 8010 if(iUpdRefIdx > 0 ) 8011 { 8012 riRefIdx = iUpdRefIdx; 8013 bIsCurrRefLongTerm = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getIsLongTerm(); 8014 iCurrRefPOC = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getPOC(); 8015 #if INTER_VIEW_VECTOR_SCALING_C0115 8016 iCurrRefViewId = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getViewOrderIdx(); // will be changed to view_id 8017 #endif 8018 } 8019 else 8020 return false; 8021 }else 8022 { 8023 #endif 7868 8024 assert( ((iColPOC == iColRefPOC)&&(iCurrPOC != iCurrRefPOC))||((iColPOC != iColRefPOC)&&(iCurrPOC == iCurrRefPOC))); 7869 8025 return false; 8026 #if QC_TMVP_MRG_REFIDX_C0047 8027 } 8028 #endif 7870 8029 } 7871 8030 #endif … … 7888 8047 } 7889 8048 }else 7890 #if QC_MVHEVC_B0046 7891 rcMv = cColMv; //inter-view 7892 #else 7893 { 7894 #if SONY_COLPIC_AVAILABILITY 7895 Int iColRefViewOrderIdx = pColCU->getSlice()->getRefPic( eColRefPicList, pColCU->getCUMvField(eColRefPicList)->getRefIdx(uiAbsPartAddr))->getViewOrderIdx(); 7896 iScale = xGetDistScaleFactor(iCurrViewOrderIdx, iCurrRefViewOrderIdx, iColViewOrderIdx, iColRefViewOrderIdx); 8049 #if INTER_VIEW_VECTOR_SCALING_C0115 8050 { 8051 if((iCurrPOC == iCurrRefPOC) && m_pcSlice->getIVScalingFlag()) // inter-view & inter-view 8052 iScale = xGetDistScaleFactor( iCurrViewId, iCurrRefViewId, iColViewId, iColRefViewId ); 8053 else 8054 iScale = 4096; // inter & inter 7897 8055 if ( iScale == 4096 ) 7898 8056 { … … 7903 8061 rcMv = cColMv.scaleMv( iScale ); 7904 8062 } 7905 #else 7906 return false; 7907 #endif 7908 } 7909 #endif 7910 } 7911 #else 7912 #if SONY_COLPIC_AVAILABILITY 7913 iScale = 0; 7914 iCurrRefViewOrderIdx = m_pcSlice->getRefPic(eRefPicList, riRefIdx)->getViewOrderIdx(); 7915 if((iColPOC != iColRefPOC)&&(iCurrPOC != iCurrRefPOC)) 7916 iScale = xGetDistScaleFactor(iCurrPOC, iCurrRefPOC, iColPOC, iColRefPOC); 7917 else if((iColPOC == iColRefPOC)&&(iCurrPOC == iCurrRefPOC)) 7918 iScale = xGetDistScaleFactor(iCurrViewOrderIdx, iCurrRefViewOrderIdx, iColViewOrderIdx, iColRefViewOrderIdx); 7919 else 7920 return false; 7921 7922 #else 7923 iScale = xGetDistScaleFactor(iCurrPOC, iCurrRefPOC, iColPOC, iColRefPOC); 7924 #endif 7925 if ( iScale == 4096 ) 7926 { 7927 rcMv = cColMv; 7928 } 7929 else 7930 { 7931 rcMv = cColMv.scaleMv( iScale ); 7932 } 7933 #endif 8063 } 8064 #else 8065 rcMv = cColMv; //inter-view 8066 #endif 8067 } 8068 #endif 8069 7934 8070 return true; 7935 8071 } … … 8906 9042 } 8907 9043 #else 9044 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 9045 Bool 9046 TComDataCU::getUnifiedMvPredCan(UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm, Bool bMerge ) 9047 { 9048 TComDepthMapGenerator* pcDepthMapGenerator = m_pcSlice->getSPS()->getDepthMapGenerator(); 9049 ROFRS( pcDepthMapGenerator, false ); 9050 if (pDInfo->iN > 0 && pcDepthMapGenerator->getPdmCandidate(this, uiPartIdx, eRefPicList, iRefIdx, paiPdmRefIdx, pacPdmMv, pDInfo, iPdm, bMerge)) 9051 return true; 9052 return false; 9053 } 9054 #else 8908 9055 Int 8909 9056 TComDataCU::getPdmMergeCandidateDisCan( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo … … 8931 9078 } 8932 9079 #endif 8933 9080 #endif 8934 9081 8935 9082 Bool -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDataCU.h
r265 r280 289 289 #endif 290 290 Void deriveRightBottomIdx ( PartSize eCUMode, UInt uiPartIdx, UInt& ruiPartIdxRB ); 291 Bool xGetColMVP( RefPicList eRefPicList, Int uiCUAddr, Int uiPartUnitIdx, TComMv& rcMv, Int& riRefIdx ); 291 Bool xGetColMVP( RefPicList eRefPicList, Int uiCUAddr, Int uiPartUnitIdx, TComMv& rcMv, Int& riRefIdx 292 #if QC_TMVP_MRG_REFIDX_C0047 293 , 294 Bool bMRG = 0 295 #endif 296 ); 292 297 #if QC_MULTI_DIS_CAN_A0097 293 298 Bool xGetColDisMV( RefPicList eRefPicList, Int refidx, Int uiCUAddr, Int uiPartUnitIdx, TComMv& rcMv, Int & iTargetViewIdx, Int & iStartViewIdx ); … … 560 565 Bool getPdmMvPred( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, Bool bMerge = false ); 561 566 #else 567 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 568 Bool getUnifiedMvPredCan(UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm, Bool bMerge ); 569 #else 562 570 Bool getPdmMvPredDisCan( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, DisInfo* pDInfo, Bool bMerge = false ); 563 571 Int getPdmMergeCandidateDisCan( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo … … 566 574 #endif 567 575 ); 576 #endif 568 577 Void getDisMvpCand ( UInt uiPartIdx, UInt uiPartAddr, DisInfo* pDInfo ); 569 578 #if LGE_DVMCP_A0126 … … 627 636 Void getPartIndexAndSize ( UInt uiPartIdx, UInt& ruiPartAddr, Int& riWidth, Int& riHeight ); 628 637 #endif 629 #if LG_RESTRICTEDRESPRED_M24766 638 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 630 639 Int getResiPredMode(UInt uiPartAddr); 631 640 Void getPUResiPredShift (Int *iPUPredResiShift, UInt uiAbsPartIndex); -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDepthMapGenerator.cpp
r249 r280 606 606 607 607 #if HHI_INTER_VIEW_MOTION_PRED 608 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 609 Bool 610 TComDepthMapGenerator::getPdmCandidate(TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm, Bool bMerge ) 611 { 612 AOF ( m_bCreated && m_bInit ); 613 TComSlice* pcSlice = pcCU->getSlice (); 614 TComSPS* pcSPS = pcSlice->getSPS(); 615 AOF ( pcSPS->getViewId() == m_uiCurrViewId ); 616 617 TComPic* pcRefPic = pcSlice->getRefPic( eRefPicList, iRefIdx ); 618 UInt uiRefViewId = pcRefPic->getSPS()->getViewId(); 619 Bool bInterview = ( uiRefViewId < m_uiCurrViewId ); 620 Bool bPdmIView = ( ( pcSPS->getMultiviewMvPredMode() & PDM_USE_FOR_IVIEW ) == PDM_USE_FOR_IVIEW ); 621 Bool bPdmInter = ( ( pcSPS->getMultiviewMvPredMode() & PDM_USE_FOR_INTER ) == PDM_USE_FOR_INTER ); 622 Bool bPdmMerge = ( ( pcSPS->getMultiviewMvPredMode() & PDM_USE_FOR_MERGE ) == PDM_USE_FOR_MERGE ); 623 if(!bMerge) 624 { 625 ROTRS( ( bInterview && !bMerge ) && !bPdmIView, false ); 626 ROTRS( (!bInterview && !bMerge ) && !bPdmInter, false ); 627 ROTRS( bMerge && !bPdmMerge, false ); 628 } 629 else 630 ROTRS( !bPdmMerge, 0 ); 631 632 #if QC_MRG_CANS_B0048 633 Bool abPdmAvailable[4] = {false, false, false, false}; 634 #else 635 Bool abPdmAvailable[2] = {false,false}; 636 #endif 637 638 Int iValid = 0; 639 Int iViewId = 0; 640 for( UInt uiBId = 0; uiBId < m_uiCurrViewId && iValid==0; uiBId++ ) 641 { 642 #if MTK_C0138_FIXED 643 UInt uiBaseId = uiBId; 644 #else 645 UInt uiBaseId = m_auiBaseIdList[ uiBId ]; 646 #endif 647 TComPic* pcBasePic = m_pcAUPicAccess->getPic( uiBaseId ); 648 for( Int iRefListId = 0; iRefListId < 2 && iValid==0; iRefListId++ ) 649 { 650 RefPicList eRefPicListTest = RefPicList( iRefListId ); 651 Int iNumRefPics = pcSlice->getNumRefIdx( eRefPicListTest ) ; 652 for( Int iRefIndex = 0; iRefIndex < iNumRefPics; iRefIndex++ ) 653 { 654 if(pcBasePic->getPOC() == pcSlice->getRefPic( eRefPicListTest, iRefIndex )->getPOC() 655 && pcBasePic->getViewId() == pcSlice->getRefPic( eRefPicListTest, iRefIndex )->getViewId()) 656 { 657 iValid=1; 658 iViewId = uiBaseId; 659 break; 660 } 661 } 662 } 663 } 664 if (iValid == 0) 665 return false; 666 667 //--- get base CU/PU and check prediction mode --- 668 TComPic* pcBasePic = m_pcAUPicAccess->getPic( iViewId ); 669 TComPicYuv* pcBaseRec = pcBasePic->getPicYuvRec (); 670 if(bMerge || !bInterview) 671 { 672 #if QC_MULTI_DIS_CAN_A0097 673 Int iCurrPosX, iCurrPosY; 674 UInt uiPartAddr; 675 Int iWidth; 676 Int iHeight; 677 678 pcCU->getPartIndexAndSize( uiPartIdx, uiPartAddr, iWidth, iHeight ); 679 pcBaseRec->getTopLeftSamplePos( pcCU->getAddr(), pcCU->getZorderIdxInCU() + uiPartAddr, iCurrPosX, iCurrPosY ); 680 iCurrPosX += ( ( iWidth - 1 ) >> 1 ); 681 iCurrPosY += ( ( iHeight - 1 ) >> 1 ); 682 683 Int iBasePosX = Clip3( 0, pcBaseRec->getWidth () - 1, iCurrPosX + ( (pDInfo->m_acMvCand[0].getHor() + 2 ) >> 2 ) ); 684 Int iBasePosY = Clip3( 0, pcBaseRec->getHeight() - 1, iCurrPosY + ( (pDInfo->m_acMvCand[0].getVer() + 2 ) >> 2 )); 685 Int iBaseCUAddr; 686 Int iBaseAbsPartIdx; 687 pcBaseRec->getCUAddrAndPartIdx( iBasePosX , iBasePosY , iBaseCUAddr, iBaseAbsPartIdx ); 688 #else 689 Int iPrdDepth, iCurrPosX, iCurrPosY; 690 Bool bAvailable = xGetPredDepth( pcCU, uiPartIdx, iPrdDepth, &iCurrPosX, &iCurrPosY ); 691 AOF( bAvailable ); 692 TComPicYuv* pcBasePdm = pcBasePic->getPredDepthMap(); 693 Int iDisparity = xGetDisparityFromVirtDepth( iViewId, iPrdDepth ); 694 Int iShiftX = m_uiSubSampExpX + 2; 695 Int iAddX = ( 1 << iShiftX ) >> 1; 696 Int iBasePosX = Clip3( 0, pcBasePdm->getWidth () - 1, iCurrPosX + ( ( iDisparity + iAddX ) >> iShiftX ) ); 697 Int iBasePosY = Clip3( 0, pcBasePdm->getHeight() - 1, iCurrPosY ); 698 Int iBaseCUAddr; 699 Int iBaseAbsPartIdx; 700 pcBaseRec->getCUAddrAndPartIdx( iBasePosX<< m_uiSubSampExpX , iBasePosY<< m_uiSubSampExpY , iBaseCUAddr, iBaseAbsPartIdx ); 701 #endif 702 TComDataCU* pcBaseCU = pcBasePic->getCU( iBaseCUAddr ); 703 if( pcBaseCU->getPredictionMode( iBaseAbsPartIdx ) == MODE_INTER || pcBaseCU->getPredictionMode( iBaseAbsPartIdx ) == MODE_SKIP ) 704 { 705 for( UInt uiCurrRefListId = 0; uiCurrRefListId < 2; uiCurrRefListId++ ) 706 { 707 RefPicList eCurrRefPicList = RefPicList( uiCurrRefListId ); 708 if(!bMerge && eCurrRefPicList != eRefPicList) 709 continue; 710 Bool bLoop_stop = false; 711 for(Int iLoop = 0; iLoop < 2 && !bLoop_stop; ++iLoop) 712 { 713 RefPicList eBaseRefPicList = (iLoop ==1)? RefPicList( 1 - uiCurrRefListId ) : RefPicList( uiCurrRefListId ); 714 TComMvField cBaseMvField; 715 pcBaseCU->getMvField( pcBaseCU, iBaseAbsPartIdx, eBaseRefPicList, cBaseMvField ); 716 Int iBaseRefIdx = cBaseMvField.getRefIdx(); 717 if (iBaseRefIdx >= 0) 718 { 719 Int iBaseRefPOC = pcBaseCU->getSlice()->getRefPOC(eBaseRefPicList, iBaseRefIdx); 720 if (iBaseRefPOC != pcSlice->getPOC()) 721 { 722 for (Int iPdmRefIdx = (bMerge?0: iRefIdx); iPdmRefIdx < (bMerge? pcSlice->getNumRefIdx( eCurrRefPicList ): (iRefIdx+1)); iPdmRefIdx++) 723 { 724 if (iBaseRefPOC == pcSlice->getRefPOC(eCurrRefPicList, iPdmRefIdx)) 725 { 726 abPdmAvailable[ uiCurrRefListId ] = true; 727 TComMv cMv(cBaseMvField.getHor(), cBaseMvField.getVer()); 728 #if LGE_DVMCP_A0126 729 if( bMerge ) 730 { 731 cMv.m_bDvMcp = true; 732 cMv.m_iDvMcpDispX = pDInfo->m_acMvCand[0].getHor(); 733 } 734 #endif 735 pcCU->clipMv( cMv ); 736 if(bMerge) 737 { 738 paiPdmRefIdx [ uiCurrRefListId ] = iPdmRefIdx; 739 pacPdmMv [ uiCurrRefListId ] = cMv; 740 bLoop_stop = true; 741 break; 742 }else 743 { 744 pacPdmMv [0] = cMv; 745 return true; 746 } 747 } 748 } 749 } 750 } 751 } 752 } 753 } 754 if( bMerge ) 755 iPdm[0] = ( abPdmAvailable[0] ? 1 : 0 ) + ( abPdmAvailable[1] ? 2 : 0 ); 756 } 757 if(bMerge || bInterview) 758 { 759 for( Int iRefListId = 0; iRefListId < 2 ; iRefListId++ ) 760 { 761 RefPicList eRefPicListDMV = RefPicList( iRefListId ); 762 Int iNumRefPics = pcSlice->getNumRefIdx( eRefPicListDMV ); 763 for( Int iPdmRefIdx = (bMerge ? 0: iRefIdx); iPdmRefIdx < (bMerge ? iNumRefPics: (iRefIdx+1) ); iPdmRefIdx++ ) 764 { 765 if( pcSlice->getRefPOC( eRefPicListDMV, iPdmRefIdx ) == pcSlice->getPOC()) 766 { 767 #if QC_MRG_CANS_B0048 768 abPdmAvailable[ iRefListId+2 ] = true; 769 paiPdmRefIdx [ iRefListId+2 ] = iPdmRefIdx; 770 #else 771 abPdmAvailable[ iRefListId ] = true; 772 paiPdmRefIdx [ iRefListId ] = iPdmRefIdx; 773 #endif 774 #if QC_MULTI_DIS_CAN_A0097 775 TComMv cMv = pDInfo->m_acMvCand[0]; 776 cMv.setVer(0); 777 #else 778 TComMv cMv(iDisparity, 0); 779 #endif 780 pcCU->clipMv( cMv ); 781 #if QC_MRG_CANS_B0048 782 pacPdmMv [ iRefListId + 2] = cMv; 783 #else 784 pacPdmMv [ iRefListId ] = cMv; 785 #endif 786 if(bMerge) 787 break; 788 else 789 { 790 pacPdmMv [0] = cMv; 791 return true; 792 } 793 } 794 } 795 } 796 #if QC_MRG_CANS_B0048 797 iPdm[1] = ( abPdmAvailable[2] ? 1 : 0 ) + ( abPdmAvailable[3] ? 2 : 0 ); 798 #else 799 iPdmInterDir = ( abPdmAvailable[0] ? 1 : 0 ) + ( abPdmAvailable[1] ? 2 : 0 ) ; 800 } 801 #endif 802 } 803 return false; 804 } 805 #else 608 806 #if QC_MULTI_DIS_CAN_A0097 609 807 Int … … 1021 1219 return false; 1022 1220 } 1221 #endif 1023 1222 #endif 1024 1223 -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDepthMapGenerator.h
r210 r280 152 152 #if HHI_INTER_VIEW_MOTION_PRED 153 153 #if QC_MULTI_DIS_CAN_A0097 154 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 155 Bool getPdmCandidate ( TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm, Bool bMerge ); 156 #else 154 157 Int getPdmMergeCandidate ( TComDataCU* pcCU, UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo 155 158 #if QC_MRG_CANS_B0048 … … 160 163 Bool getPdmMvPredDisCan ( TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, DisInfo* pDInfo, Bool bMerge ); 161 164 Bool getDisCanPdmMvPred ( TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, DisInfo* pDInfo, Bool bMerge ); 165 #endif 162 166 #else 163 167 Int getPdmMergeCandidate ( TComDataCU* pcCU, UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv ); -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComPic.cpp
r231 r280 76 76 m_pcUsedPelsMap = NULL; 77 77 #endif 78 #if SONY_COLPIC_AVAILABILITY79 m_iViewOrderIdx = 0; 78 #if INTER_VIEW_VECTOR_SCALING_C0115 79 m_iViewOrderIdx = 0; // will be changed to view_id 80 80 #endif 81 81 m_aaiCodedScale = 0; … … 703 703 } 704 704 705 705 706 //! \} -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComPic.h
r210 r280 112 112 TComPicYuv* m_pcUsedPelsMap; 113 113 #endif 114 #if SONY_COLPIC_AVAILABILITY115 Int m_iViewOrderIdx; 114 #if INTER_VIEW_VECTOR_SCALING_C0115 115 Int m_iViewOrderIdx; // will be changed to view_id 116 116 #endif 117 117 Int** m_aaiCodedScale; … … 188 188 #endif 189 189 190 #if SONY_COLPIC_AVAILABILITY191 Void setViewOrderIdx(Int i) { m_iViewOrderIdx = i; } 192 Int getViewOrderIdx() { return m_iViewOrderIdx; } 190 #if INTER_VIEW_VECTOR_SCALING_C0115 191 Void setViewOrderIdx(Int i) { m_iViewOrderIdx = i; } // will be changed to view_id 192 Int getViewOrderIdx() { return m_iViewOrderIdx; } // will be changed to view_id 193 193 #endif 194 194 -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComPrediction.cpp
r275 r280 847 847 } 848 848 849 849 #if MTK_MDIVRP_C0138 850 Void TComPrediction::residualPrediction(TComDataCU* pcCU, TComYuv* pcYuvPred, TComYuv* pcYuvResPred) 851 { 852 Int iWidth; 853 Int iHeight; 854 UInt uiPartAddr; 855 856 pcCU->getPartIndexAndSize( 0, uiPartAddr, iWidth, iHeight ); 857 858 Bool bResAvail = false; 859 860 bResAvail = pcCU->getResidualSamples( 0, 861 #if QC_SIMPLIFIEDIVRP_M24938 862 true, 863 #endif 864 pcYuvResPred ); 865 866 assert (bResAvail); 867 868 pcYuvPred->add(pcYuvResPred, iWidth, iHeight); 869 } 870 #endif 850 871 851 872 #if DEPTH_MAP_GENERATION -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComPrediction.h
r275 r280 189 189 #endif 190 190 191 #if MTK_MDIVRP_C0138 192 Void residualPrediction (TComDataCU* pcCU, TComYuv* pcYuvPred, TComYuv* pcYuvResPred); 193 #endif 191 194 192 195 // motion vector prediction -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComResidualGenerator.cpp
r259 r280 184 184 AOF ( pcPic ); 185 185 186 #if MTK_MDIVRP_C0138 187 if (pcPic->getSPS()->getViewId() != 0) 188 { 189 return; 190 } 191 #endif 192 186 193 if( pcPic->getPOC() == 0 ) 187 194 { … … 300 307 #endif 301 308 { 309 #if MTK_C0138_FIXED 310 UInt uiBaseViewId = 0; 311 #else 302 312 UInt uiBaseViewId = m_pcDepthMapGenerator->getBaseViewId( 0 ); 303 313 #endif 304 314 if( !pcYuv ) 305 315 { … … 330 340 ); 331 341 #endif 342 #if MTK_MDIVRP_C0138 343 return true; 344 #else 332 345 #if QC_SIMPLIFIEDIVRP_M24938 333 346 return xIsNonZeroByCBF( uiBaseViewId , uiXPosInRefView , uiYPosInRefView , uiBlkWidth , uiBlkHeight ); 334 347 #else 335 348 return xIsNonZero( pcYuv, uiBlkWidth, uiBlkHeight ); 349 #endif 336 350 #endif 337 351 } … … 453 467 Pel* pRes = pcCUResidual->getLumaAddr(); 454 468 UInt uiLumaTrMode, uiChromaTrMode; 455 #if LG_RESTRICTEDRESPRED_M24766 469 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 456 470 Int iPUPredResiShift[4]; 457 471 #endif … … 479 493 m_pcTrQuant->invRecurTransformNxN ( pcCU, 0, TEXT_CHROMA_V, pRes, 0, pcCUResidual->getCStride(), uiWidth, uiHeight, uiChromaTrMode, 0, piCoeff ); 480 494 495 #if !MTK_MDIVRP_C0138 481 496 if( pcCU->getResPredFlag( 0 ) ) 482 497 { … … 495 510 #endif 496 511 } 512 #endif 497 513 498 514 //===== clear inter-view predicted parts ===== -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComSlice.cpp
r231 r280 113 113 , m_numEntryPointOffsets ( 0 ) 114 114 #endif 115 #if SONY_COLPIC_AVAILABILITY116 , m_iViewOrderIdx ( 0 )117 #endif118 115 #if LGE_ILLUCOMP_B0045 119 116 , m_bApplyIC ( false ) 117 #endif 118 #if INTER_VIEW_VECTOR_SCALING_C0115 119 , m_bIVScalingFlag (false) 120 , m_iViewOrderIdx ( 0 ) // will be changed to view_id 120 121 #endif 121 122 { … … 198 199 #if TILES_WPP_ENTRY_POINT_SIGNALLING 199 200 m_numEntryPointOffsets = 0; 201 #endif 202 #if QC_TMVP_MRG_REFIDX_C0047 203 m_aiNewRefIdx[0] = -1; 204 m_aiNewRefIdx[1] = -1; 200 205 #endif 201 206 } … … 419 424 } 420 425 } 426 #if QC_TMVP_MRG_REFIDX_C0047 427 Int iCurrPOC = this->getPOC(); 428 for ( UInt uiRefListIdx = 0; uiRefListIdx < 2; uiRefListIdx++ )//just to get one updated ref idx for merge in each L0/L1 direction, if it is not avaialbe, it is still -1 429 { 430 if ( this->getNumRefIdx( RefPicList( uiRefListIdx ) ) == 0) 431 continue; 432 433 Bool bZeroIdxInterViewFlag = ( this->getRefPic(RefPicList(uiRefListIdx), 0)->getPOC() == iCurrPOC ) ? true : false; 434 for(Int i = 1; i < this->getNumRefIdx(RefPicList(uiRefListIdx)); i++ ) 435 { 436 if ( (bZeroIdxInterViewFlag && this->getRefPic(RefPicList(uiRefListIdx), i)->getPOC() != iCurrPOC ) || 437 (!bZeroIdxInterViewFlag && this->getRefPic(RefPicList(uiRefListIdx), i)->getPOC() == iCurrPOC ) ) 438 { 439 this->setNewRefIdx(RefPicList(uiRefListIdx),i); 440 break; 441 } 442 } 443 } 444 445 #endif 421 446 } 422 447 … … 698 723 m_iPOC = pSrc->m_iPOC; 699 724 m_viewId = pSrc->m_viewId; 700 #if SONY_COLPIC_AVAILABILITY 701 m_iViewOrderIdx = pSrc->m_iViewOrderIdx; 725 #if INTER_VIEW_VECTOR_SCALING_C0115 726 m_iViewOrderIdx = pSrc->m_iViewOrderIdx;// will be changed to view_id 727 m_bIVScalingFlag = pSrc->m_bIVScalingFlag; 702 728 #endif 703 729 m_eNalUnitType = pSrc->m_eNalUnitType; -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComSlice.h
r231 r280 179 179 UInt m_uiMaxDecPicBuffering[MAX_TLAYER]; 180 180 UInt m_uiMaxLatencyIncrease[MAX_TLAYER]; 181 181 #if INTER_VIEW_VECTOR_SCALING_C0115 182 Bool m_bIVScalingFlag; 183 #endif 182 184 public: 183 185 TComVPS(); … … 213 215 Void setDependentLayer(UInt v, UInt layer) { m_uiDependentLayer[layer] = v; } 214 216 UInt getDependentLayer(UInt layer) { return m_uiDependentLayer[layer]; } 217 #endif 218 #if INTER_VIEW_VECTOR_SCALING_C0115 219 Bool getIVScalingFlag( ) { return m_bIVScalingFlag; } 220 Void setIVScalingFlag(Bool b) { m_bIVScalingFlag = b; } 215 221 #endif 216 222 Void setNumReorderPics(UInt v, UInt tLayer) { m_numReorderPics[tLayer] = v; } … … 1248 1254 1249 1255 Bool m_bCheckLDC; 1256 #if QC_TMVP_MRG_REFIDX_C0047 1257 Int m_aiNewRefIdx [2]; 1258 #endif 1250 1259 1251 1260 // Data … … 1340 1349 Int m_aaiCodedOffset[2][MAX_VIEW_NUM]; 1341 1350 1342 #if SONY_COLPIC_AVAILABILITY|QC_MVHEVC_B00461343 Int m_iViewOrderIdx;1344 #endif1345 1351 #if LGE_ILLUCOMP_B0045 1346 1352 Bool m_bApplyIC; 1353 #endif 1354 #if INTER_VIEW_VECTOR_SCALING_C0115|QC_MVHEVC_B0046 1355 Bool m_bIVScalingFlag; 1356 Int m_iViewOrderIdx; // will be changed to view_id 1347 1357 #endif 1348 1358 … … 1437 1447 Int getRefViewId ( RefPicList e, Int iRefIdx) { return m_aiRefViewIdList[e][iRefIdx]; } 1438 1448 TComPic* getTexturePic () const { return m_pcTexturePic; } 1439 #if SONY_COLPIC_AVAILABILITY1440 Int getViewOrderIdx () { return m_iViewOrderIdx; }1441 #endif1442 1449 Int getDepth () { return m_iDepth; } 1443 1450 UInt getColDir () { return m_uiColDir; } … … 1489 1496 Void setRefViewId ( Int i, RefPicList e, Int iRefIdx ) { m_aiRefViewIdList[e][iRefIdx] = i; } 1490 1497 Void setTexturePic ( TComPic *pcTexturePic ) { m_pcTexturePic = pcTexturePic; } 1491 #if SONY_COLPIC_AVAILABILITY1492 Void setViewOrderIdx ( Int i ) { m_iViewOrderIdx = i; }1493 #endif1494 1498 Void setNumRefIdx ( RefPicList e, Int i ) { m_aiNumRefIdx[e] = i; } 1495 1499 Void setPic ( TComPic* p ) { m_pcPic = p; } … … 1661 1665 Void xSetApplyIC (); 1662 1666 #endif 1667 #if QC_TMVP_MRG_REFIDX_C0047 1668 Int getNewRefIdx ( RefPicList e ) { return m_aiNewRefIdx[e]; } 1669 Void setNewRefIdx ( RefPicList e, Int i ) { m_aiNewRefIdx[e] = i; } 1670 #endif 1671 #if INTER_VIEW_VECTOR_SCALING_C0115 1672 Void setIVScalingFlag( Bool val ) { m_bIVScalingFlag = val; } 1673 Bool getIVScalingFlag() { return m_bIVScalingFlag; } 1674 Void setViewOrderIdx ( Int i ) { m_iViewOrderIdx = i; } // will be changed to view_id 1675 Int getViewOrderIdx () { return m_iViewOrderIdx; } // will be changed to view_id 1676 #endif 1663 1677 1664 1678 #if MERL_VSP_C0152 -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComYuv.cpp
r189 r280 392 392 } 393 393 394 #if LG_RESTRICTEDRESPRED_M24766 394 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 395 395 Void 396 396 TComYuv::add(Int *iPUResiPredShift, PartSize uhPartitionSize, TComYuv* pcYuvAdd, Int iWidth, Int iHeight, Bool bSubtract ) … … 408 408 #endif 409 409 410 #if LG_RESTRICTEDRESPRED_M24766 410 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 411 411 Void 412 412 TComYuv::getPUXYOffset(PartSize uhPartitionSize, Int iWidth, Int iHeight, Int &iXOffset, Int &iYOffset) … … 435 435 #endif 436 436 437 #if LG_RESTRICTEDRESPRED_M24766 437 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 438 438 Void 439 439 TComYuv::addLuma(Int *iPUResiPredShift, PartSize uhPartitionSize, TComYuv* pcYuvAdd, Int iWidth, Int iHeight, Bool bSubtract ) … … 449 449 Pel* pDstSamples = getLumaAddr(); 450 450 451 #if LG_RESTRICTEDRESPRED_M24766 451 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 452 452 Int iXOffset, iYOffset; 453 453 … … 502 502 } 503 503 504 #if LG_RESTRICTEDRESPRED_M24766 504 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 505 505 Void 506 506 TComYuv::addChroma(Int *iPUResiPredShift, PartSize uhPartitionSize, TComYuv* pcYuvAdd, Int iWidth, Int iHeight, Bool bSubtract ) … … 518 518 Pel* pDstSamplesCr = getCrAddr(); 519 519 520 #if LG_RESTRICTEDRESPRED_M24766 520 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 521 521 Int iXOffset, iYOffset; 522 522 … … 676 676 } 677 677 678 #if LG_RESTRICTEDRESPRED_M24766 678 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 679 679 Void TComYuv::subtract(Int *iPUResiPredShift, PartSize uhPartitionSize, TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiTrUnitIdx, UInt uiPartSize ) 680 680 { … … 690 690 #endif 691 691 692 #if LG_RESTRICTEDRESPRED_M24766 692 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 693 693 Void TComYuv::subtractLuma(Int *iPUResiPredShift, PartSize uhPartitionSize, TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiTrUnitIdx, UInt uiPartSize ) 694 694 #else … … 706 706 Int iDstStride = getStride(); 707 707 708 #if LG_RESTRICTEDRESPRED_M24766 708 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 709 709 Int iXOffset, iYOffset; 710 710 … … 814 814 } 815 815 816 #if LG_RESTRICTEDRESPRED_M24766 816 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 817 817 Void TComYuv::subtractChroma(Int *iPUResiPredShift, PartSize uhPartitionSize, TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiTrUnitIdx, UInt uiPartSize ) 818 818 #else … … 832 832 Int iSrc1Stride = pcYuvSrc1->getCStride(); 833 833 Int iDstStride = getCStride(); 834 #if LG_RESTRICTEDRESPRED_M24766 834 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 835 835 Int iXOffset, iYOffset; 836 836 -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComYuv.h
r100 r280 146 146 Void addClipPartLuma ( TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiTrUnitIdx, UInt uiPartSize ); //GT 147 147 148 #if LG_RESTRICTEDRESPRED_M24766 148 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 149 149 // pcYuvSrc0 - pcYuvSrc1 -> m_apiBuf 150 150 Void subtract (Int *iPUResiPredShift, PartSize uhPartitionSize, TComYuv* pcYuvSrc0, TComYuv* pcYuvSrc1, UInt uiTrUnitIdx, UInt uiPartSize ); … … 166 166 // Remove High frequency 167 167 Void removeHighFreq ( TComYuv* pcYuvSrc, UInt uiPartIdx, UInt uiWidht, UInt uiHeight ); 168 #if LG_RESTRICTEDRESPRED_M24766 168 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 169 169 Void getPUXYOffset (PartSize uhPartitionSize, Int iWidth, Int iHeight, Int &iXOffset, Int &iYOffset); 170 170 Void add (Int *iPUResiPredShift, PartSize uhPartitionSize, TComYuv* pcYuvAdd, Int iWidth, Int iHeight, Bool bSubtract = false ); -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TypeDef.h
r276 r280 77 77 #define DISABLE_FCO_FOR_VSO 0 // Optional compile settings to disable VSO with FCO. 78 78 #endif 79 #define QC_TMVP_MRG_REFIDX_C0047 1 //only enabled when QC_TMVP_IDX_MOD_B0046 is enabled. 79 80 80 81 ///// ***** PATCHES ********* … … 90 91 ///// ***** INTERVIEW MOTION VECTOR PREDICTION ********* 91 92 #define HHI_INTER_VIEW_MOTION_PRED 1 // inter-view motion parameter prediction 93 #define QC_AMVP_MRG_UNIFY_IVCAN_C0051 1 94 #define QC_C0051_FIXED_BY_MTK 1 // bug fix for C0051 implementation 92 95 #define SHARP_INTERVIEW_DECOUPLE_B0111 1 // JCT3V-B0111 decoupling inter-view candidate 93 96 #define QC_MRG_CANS_B0048 1 // JCT3V-B0048, B0086, B0069 … … 105 108 #define HHI_INTER_VIEW_RESIDUAL_PRED 1 // inter-view residual prediction 106 109 #if HHI_INTER_VIEW_RESIDUAL_PRED 110 #define MTK_MDIVRP_C0138 1 // mode-dependent inter-view residual prediction 111 #define MTK_C0138_FIXED 1 // fix for IBP coding structure in view direction (not CTC) 107 112 #define LG_RESTRICTEDRESPRED_M24766 1 // restricted inter-view residual prediction 108 113 #define QC_SIMPLIFIEDIVRP_M24938 1 … … 119 124 #define QC_SIMPLE_NBDV_B0047 1 // JCT3V-B0047 120 125 ///// ***** MOTION PARAMETER INHERITANCE ********* 121 #define HHI_MPI 1 // motion parameter inheritance from texture picture for depth map coding 126 #define MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 1 // JCT3V-C0137 127 #define HHI_MPI 0 // motion parameter inheritance from texture picture for depth map coding 122 128 #if HHI_MPI 123 129 #define FIX_MPI_B0065 1 // JCT3V-B0065, fix the MPI bug when RQT is off … … 151 157 ///// ***** OTHERS ********* 152 158 #define LG_ZEROINTRADEPTHRESI_A0087 1 // JCT2-A0087 153 #define SONY_COLPIC_AVAILABILITY 1 159 #define INTER_VIEW_VECTOR_SCALING_C0115 1 // JCT2-C0115 Inter-view vector scaling for TMVP & flag 160 #define INTER_VIEW_VECTOR_SCALING_C0116 1 // JCT2-C0116 Inter-view vector scaling for AMVP 154 161 #define HHI_FULL_PEL_DEPTH_MAP_MV_ACC 1 // full-pel mv accuracy for depth maps 155 162 #define VIDYO_VPS_INTEGRATION 1 -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecCAVLC.cpp
r210 r280 1458 1458 } 1459 1459 } 1460 #if INTER_VIEW_VECTOR_SCALING_C0115 1461 READ_FLAG( uiCode, "inter_view_vector_scaling_flag" ); pcVPS->setIVScalingFlag( uiCode ? true:false); 1462 #endif 1460 1463 } 1461 1464 … … 1468 1471 #endif 1469 1472 #endif 1470 #if HHI_MPI 1473 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 1471 1474 Void TDecCavlc::parseSPS(TComSPS* pcSPS, Bool bIsDepth) 1472 1475 #else … … 1892 1895 1893 1896 #if LCU_SYNTAX_ALF 1897 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 1898 Void TDecCavlc::parseSliceHeader (TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet, bool isDepth) 1899 #else 1894 1900 Void TDecCavlc::parseSliceHeader (TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet) 1901 #endif 1895 1902 #else 1896 1903 Void TDecCavlc::parseSliceHeader (TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl) … … 2495 2502 #elif HHI_MPI 2496 2503 const int iExtraMergeCandidates = sps->getUseMVI() ? 1 : 0; 2504 #elif MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 2505 const int iExtraMergeCandidates = ( (isDepth || sps->getMultiviewMvPredMode()) ) ? 1 : 0; 2497 2506 #else 2498 2507 const int iExtraMergeCandidates = sps->getMultiviewMvPredMode() ? 1 : 0; -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecCAVLC.h
r210 r280 118 118 Void parseVPS ( TComVPS* pcVPS ); 119 119 #endif 120 #if HHI_MPI 120 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 121 121 Void parseSPS ( TComSPS* pcSPS, Bool bIsDepth ); 122 122 #else … … 131 131 Void parseAPS ( TComAPS* pAPS ); 132 132 #if LCU_SYNTAX_ALF 133 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 134 Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet, bool isDepth); 135 #else 133 136 Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet); 137 #endif 134 138 #else 135 139 Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl ); -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecCu.cpp
r275 r280 424 424 } 425 425 #endif 426 #if HHI_INTER_VIEW_RESIDUAL_PRED 426 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 427 427 m_pcEntropyDecoder->decodeResPredFlag( pcCU, uiAbsPartIdx, uiDepth, m_ppcCU[uiDepth], 0 ); 428 428 #endif … … 476 476 #endif 477 477 478 #if HHI_INTER_VIEW_RESIDUAL_PRED 478 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 479 479 if( !pcCU->isIntra( uiAbsPartIdx ) ) 480 480 { … … 692 692 m_pcPrediction->motionCompensation( pcCU, m_ppcYuvReco[uiDepth] ); 693 693 #endif 694 #if MTK_MDIVRP_C0138 695 if (pcCU->getMergeFlag(0) && pcCU->getMergeIndex(0)==0 && pcCU->getResPredAvail(0)) 696 { 697 m_pcPrediction->residualPrediction(pcCU, m_ppcYuvReco[uiDepth], m_ppcYuvResPred[uiDepth]); 698 } 699 #endif 700 694 701 #if HHI_MPI 695 702 if( pcCU->getTextureModeDepth( 0 ) != -1 ) … … 697 704 #endif 698 705 699 #if HHI_INTER_VIEW_RESIDUAL_PRED 706 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 700 707 if( pcCU->getResPredFlag( 0 ) ) 701 708 { … … 728 735 { 729 736 #if HHI_INTER_VIEW_RESIDUAL_PRED 737 #if MTK_MDIVRP_C0138 738 if (pcCU->getMergeFlag(0) && pcCU->getMergeIndex(0)==0 && pcCU->getResPredAvail(0)) 739 #else 730 740 if( pcCU->getResPredFlag( 0 ) ) 741 #endif 731 742 { 732 743 m_ppcYuvReco[uiDepth]->clip( pcCU->getWidth( 0 ), pcCU->getHeight( 0 ) ); … … 1079 1090 // reconstruct residual based on mask + DC residuals 1080 1091 Pel apDCResiValues[2]; 1081 //Pel apDCRecoValues[2];1092 Pel apDCRecoValues[2]; 1082 1093 for( UInt ui = 0; ui < uiNumSegments; ui++ ) 1083 1094 { … … 1086 1097 Pel pRecoValue = GetIdx2DepthValue( pPredIdx + pResiIdx ); 1087 1098 1088 //apDCRecoValues[ui] = pRecoValue;1099 apDCRecoValues[ui] = pRecoValue; 1089 1100 apDCResiValues[ui] = pRecoValue - apDCPredValues[ui]; 1090 1101 } -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecEntropy.cpp
r231 r280 100 100 } 101 101 102 #if HHI_INTER_VIEW_RESIDUAL_PRED 102 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 103 103 Void 104 104 TDecEntropy::decodeResPredFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, TComDataCU* pcSubCU, UInt uiPUIdx ) … … 341 341 pcSubCU->getInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, uiDepth, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, iVSPIndexTrue, uiMergeIndex ); 342 342 343 #if HHI_MPI 343 344 if(pcCU->getTextureModeDepth( uiSubPartIdx ) == uiDepth)//MPI is used 344 345 { … … 352 353 } 353 354 else // MPI not used 355 #endif 354 356 { 355 357 Int iVSPIdx = 0; -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecEntropy.h
r210 r280 74 74 virtual Void parseVPS ( TComVPS* pcVPS ) = 0; 75 75 #endif 76 #if HHI_MPI 76 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 77 77 virtual Void parseSPS ( TComSPS* pcSPS, Bool bIsDepth ) = 0; 78 78 #else … … 88 88 89 89 #if LCU_SYNTAX_ALF 90 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 91 virtual Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet, bool isDepth) = 0; 92 #else 90 93 virtual Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet) = 0; 94 #endif 91 95 #else 92 96 virtual Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl ) = 0; … … 179 183 #endif 180 184 181 #if HHI_MPI 185 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 182 186 Void decodeSPS ( TComSPS* pcSPS, Bool bIsDepth ) { m_pcEntropyDecoderIf->parseSPS(pcSPS, bIsDepth); } 183 187 #else … … 193 197 194 198 #if LCU_SYNTAX_ALF 199 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 200 Void decodeSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet, bool isDepth) { m_pcEntropyDecoderIf->parseSliceHeader(rpcSlice, parameterSetManager, alfCUCtrl, alfParamSet, isDepth); } 201 #else 195 202 Void decodeSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet) { m_pcEntropyDecoderIf->parseSliceHeader(rpcSlice, parameterSetManager, alfCUCtrl, alfParamSet); } 203 #endif 196 204 #else 197 205 Void decodeSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl ) { m_pcEntropyDecoderIf->parseSliceHeader(rpcSlice, parameterSetManager, alfCUCtrl); } … … 210 218 Void decodeMergeFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPUIdx ); 211 219 Void decodeMergeIndex ( TComDataCU* pcSubCU, UInt uiPartIdx, UInt uiPartAddr, PartSize eCUMode, UChar* puhInterDirNeighbours, TComMvField* pcMvFieldNeighbours, UInt uiDepth ); 212 #if HHI_INTER_VIEW_RESIDUAL_PRED 220 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 213 221 Void decodeResPredFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, TComDataCU* pcSubCU, UInt uiPUIdx ); 214 222 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecSbac.h
r210 r280 90 90 Void parseVPS ( TComVPS* pcVPS ) {} 91 91 #endif 92 #if HHI_MPI 92 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 93 93 Void parseSPS ( TComSPS* pcSPS, Bool bIsDepth ) {} 94 94 #else … … 104 104 105 105 #if LCU_SYNTAX_ALF 106 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 107 Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet, bool isDepth) {} 108 #else 106 109 Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl, AlfParamSet& alfParamSet) {} 110 #endif 107 111 #else 108 112 Void parseSliceHeader ( TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, AlfCUCtrlInfo &alfCUCtrl ) {} -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecTop.cpp
r231 r280 353 353 m_iMaxRefPicNum = 0; 354 354 m_uiValidPS = 0; 355 #if SONY_COLPIC_AVAILABILITY356 m_iViewOrderIdx = 0;357 #endif358 355 #if ENC_DEC_TRACE 359 356 if(!g_hTrace) g_hTrace = fopen( "TraceDec.txt", "wb" ); … … 788 785 } 789 786 790 #if SONY_COLPIC_AVAILABILITY791 m_apcSlicePilot->setViewOrderIdx( m_apcSlicePilot->getSPS()->getViewOrderIdx());792 #endif793 794 787 #if NAL_REF_FLAG 795 788 m_apcSlicePilot->setReferenced(nalu.m_nalRefFlag); … … 801 794 // ALF CU parameters should be part of the slice header -> needs to be fixed 802 795 #if LCU_SYNTAX_ALF 796 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 797 m_cEntropyDecoder.decodeSliceHeader (m_apcSlicePilot, &m_parameterSetManagerDecoder, m_cGopDecoder.getAlfCuCtrlParam(), m_cGopDecoder.getAlfParamSet(),m_apcSlicePilot->getVPS()->getDepthFlag(nalu.m_layerId)); 798 #else 803 799 m_cEntropyDecoder.decodeSliceHeader (m_apcSlicePilot, &m_parameterSetManagerDecoder, m_cGopDecoder.getAlfCuCtrlParam(), m_cGopDecoder.getAlfParamSet()); 800 #endif 804 801 #else 805 802 m_cEntropyDecoder.decodeSliceHeader (m_apcSlicePilot, &m_parameterSetManagerDecoder, m_cGopDecoder.getAlfCuCtrlParam() ); … … 865 862 xGetNewPicBuffer (m_apcSlicePilot, pcPic); 866 863 867 #if SONY_COLPIC_AVAILABILITY 868 pcPic->setViewOrderIdx( m_apcSlicePilot->getSPS()->getViewOrderIdx() ); 869 #endif 870 864 #if INTER_VIEW_VECTOR_SCALING_C0115 865 pcPic->setViewOrderIdx( m_apcSlicePilot->getVPS()->getViewOrderIdx(nalu.m_layerId) ); // will be changed to view_id 866 #endif 871 867 /* transfer any SEI messages that have been received to the picture */ 872 868 pcPic->setSEIs(m_SEIs); … … 1093 1089 #endif 1094 1090 1095 #if SONY_COLPIC_AVAILABILITY1091 #if INTER_VIEW_VECTOR_SCALING_C0115 1096 1092 #if VIDYO_VPS_INTEGRATION 1097 pcSlice->setViewOrderIdx( pcSlice->getVPS()->getViewOrderIdx(nalu.m_layerId) ); 1093 pcSlice->setViewOrderIdx( pcSlice->getVPS()->getViewOrderIdx(nalu.m_layerId) ); // will be changed to view_id 1098 1094 #else 1099 1095 pcSlice->setViewOrderIdx( pcPic->getViewOrderIdx() ); 1100 1096 #endif 1097 #endif 1098 1099 #if INTER_VIEW_VECTOR_SCALING_C0115 1100 pcSlice->setIVScalingFlag( pcSlice->getVPS()->getIVScalingFlag()); 1101 1101 #endif 1102 1102 … … 1269 1269 sps->setRPSList(rps); 1270 1270 #endif 1271 #if HHI_MPI 1271 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 1272 1272 m_cEntropyDecoder.decodeSPS( sps, m_isDepth ); 1273 1273 #else -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecTop.h
r231 r280 196 196 SEImessages *m_SEIs; ///< "all" SEI messages. If not NULL, we own the object. 197 197 198 #if SONY_COLPIC_AVAILABILITY199 Int m_iViewOrderIdx;200 #endif201 202 198 // functional classes 203 199 TComPrediction m_cPrediction; … … 264 260 Void setIsDepth( Bool isDepth ) { m_isDepth = isDepth; } 265 261 266 #if SONY_COLPIC_AVAILABILITY267 Void setViewOrderIdx(Int i) { m_iViewOrderIdx = i ;}268 Int getViewOrderIdx() { return m_iViewOrderIdx ; }269 #endif270 271 262 #if DEPTH_MAP_GENERATION 272 263 TComDepthMapGenerator* getDepthMapGenerator () { return &m_cDepthMapGenerator; } -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCavlc.cpp
r210 r280 498 498 } 499 499 } 500 #if INTER_VIEW_VECTOR_SCALING_C0115 501 WRITE_FLAG( pcVPS->getIVScalingFlag(), "inter_view_vector_scaling_flag" ); 502 #endif 500 503 } 501 504 … … 508 511 #endif 509 512 #endif 510 #if HHI_MPI 513 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 511 514 Void TEncCavlc::codeSPS( TComSPS* pcSPS, Bool bIsDepth ) 512 515 #else … … 1304 1307 #elif HHI_MPI 1305 1308 const int iExtraMergeCandidates = pcSlice->getSPS()->getUseMVI() ? 1 : 0; 1309 #elif MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 1310 const int iExtraMergeCandidates = ( pcSlice->getIsDepth() || pcSlice->getSPS()->getMultiviewMvPredMode() ) ? 1 : 0; 1306 1311 #else 1307 1312 const int iExtraMergeCandidates = pcSlice->getSPS()->getMultiviewMvPredMode() ? 1 : 0; -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCavlc.h
r210 r280 118 118 #endif 119 119 120 #if HHI_MPI 120 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 121 121 Void codeSPS ( TComSPS* pcSPS, Bool bIsDepth ); 122 122 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCfg.h
r210 r280 170 170 Bool m_bUseIC; 171 171 #endif 172 #if INTER_VIEW_VECTOR_SCALING_C0115 173 Bool m_bUseIVS; 174 #endif 172 175 #if SAO_UNIT_INTERLEAVING 173 176 Int m_maxNumOffsetsPerPic; … … 713 716 Void setUseIC ( Bool bVal ) {m_bUseIC = bVal;} 714 717 Bool getUseIC () {return m_bUseIC;} 718 #endif 719 #if INTER_VIEW_VECTOR_SCALING_C0115 720 Void setUseIVS ( Bool bVal ) {m_bUseIVS = bVal;} 721 Bool getUseIVS () {return m_bUseIVS;} 715 722 #endif 716 723 #if SAO_UNIT_INTERLEAVING … … 869 876 Void setCodedOffset ( Int** p ) { m_aaiCodedOffset = p; } 870 877 871 #if SONY_COLPIC_AVAILABILITY872 Int getViewOrderIdx () { return m_iViewOrderIdx; } 878 #if INTER_VIEW_VECTOR_SCALING_C0115 879 Int getViewOrderIdx () { return m_iViewOrderIdx; } // will be changed to view_id 873 880 #endif 874 881 }; -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCu.cpp
r275 r280 636 636 { 637 637 #if HHI_INTER_VIEW_RESIDUAL_PRED 638 #if MTK_MDIVRP_C0138 639 Bool bResPredAvailable = false; 640 UInt uiResPrdId = 0; 641 #else 638 642 // check availability of residual prediction 639 643 Bool bResPredAvailable = false; … … 651 655 652 656 for( UInt uiResPrdId = 0; uiResPrdId < ( bResPredAvailable ? 2 : 1 ); uiResPrdId++ ) 657 #endif 653 658 { 654 659 Bool bResPredFlag = ( uiResPrdId > 0 ); … … 764 769 { 765 770 #if HHI_INTER_VIEW_RESIDUAL_PRED 771 #if MTK_MDIVRP_C0138 772 Bool bResPredAvailable = false; 773 UInt uiResPrdId = 0; 774 #else 766 775 // check availability of residual prediction 767 776 Bool bResPredAvailable = false; … … 779 788 780 789 for( UInt uiResPrdId = 0; uiResPrdId < ( bResPredAvailable ? 2 : 1 ); uiResPrdId++ ) 790 #endif 781 791 { 782 792 Bool bResPredFlag = ( uiResPrdId > 0 ); … … 1789 1799 m_pcEntropyCoder->encodeICFlag ( pcCU, uiAbsPartIdx ); 1790 1800 #endif 1791 #if HHI_INTER_VIEW_RESIDUAL_PRED 1801 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 1792 1802 m_pcEntropyCoder->encodeResPredFlag( pcCU, uiAbsPartIdx, 0 ); 1793 1803 #endif … … 1820 1830 m_pcEntropyCoder->encodeICFlag ( pcCU, uiAbsPartIdx ); 1821 1831 #endif 1822 #if HHI_INTER_VIEW_RESIDUAL_PRED 1832 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 1823 1833 if( !pcCU->isIntra( uiAbsPartIdx ) ) 1824 1834 { … … 1860 1870 Int numValidMergeCand = 0; 1861 1871 1862 #if HHI_INTER_VIEW_RESIDUAL_PRED 1872 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 1863 1873 Bool bResPrdAvail = rpcTempCU->getResPredAvail( 0 ); 1864 1874 Bool bResPrdFlag = rpcTempCU->getResPredFlag ( 0 ); … … 1896 1906 rpcTempCU->getInterMergeCandidates( 0, 0, uhDepth, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand ); 1897 1907 #endif 1908 #if MTK_MDIVRP_C0138 1909 Bool bResPredAvail = rpcTempCU->getResPredAvail(0); 1910 #endif 1911 1898 1912 #if FAST_DECISION_FOR_MRG_RD_COST 1899 1913 Bool bestIsSkip = false; … … 1958 1972 1959 1973 #if HHI_INTER_VIEW_RESIDUAL_PRED 1974 #if MTK_MDIVRP_C0138 1975 rpcTempCU->setResPredAvailSubParts(bResPredAvail, 0, 0, uhDepth); 1976 #else 1960 1977 rpcTempCU->setResPredAvailSubParts( bResPrdAvail, 0, 0, uhDepth ); 1961 1978 rpcTempCU->setResPredFlagSubParts ( bResPrdFlag, 0, 0, uhDepth ); 1979 #endif 1962 1980 #endif 1963 1981 #if LGE_ILLUCOMP_B0045 … … 1976 1994 #else 1977 1995 m_pcPredSearch->motionCompensation ( rpcTempCU, m_ppcPredYuvTemp[uhDepth] ); 1996 #endif 1997 #if MTK_MDIVRP_C0138 1998 if (uiMergeCand == 0 && rpcTempCU->getResPredAvail(0)) 1999 { 2000 m_pcPredSearch->residualPrediction(rpcTempCU, m_ppcPredYuvTemp[uhDepth], m_ppcResPredTmp [uhDepth]); 2001 } 1978 2002 #endif 1979 2003 // save pred adress … … 1990 2014 #else 1991 2015 m_pcPredSearch->motionCompensation ( rpcTempCU, m_ppcPredYuvTemp[uhDepth] ); 2016 #endif 2017 #if MTK_MDIVRP_C0138 2018 if (uiMergeCand == 0 && rpcTempCU->getResPredAvail(0)) 2019 { 2020 m_pcPredSearch->residualPrediction(rpcTempCU, m_ppcPredYuvTemp[uhDepth], m_ppcResPredTmp [uhDepth]); 2021 } 1992 2022 #endif 1993 2023 // save pred adress … … 2112 2142 rpcTempCU->setMergeAMP (true); 2113 2143 #if HHI_INTERVIEW_SKIP 2114 #if LG_RESTRICTEDRESPRED_M24766 2144 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 2115 2145 m_pcPredSearch->predInterSearch ( rpcTempCU, m_ppcOrigYuv[uhDepth], m_ppcResPredTmp[uhDepth], m_ppcPredYuvTemp[uhDepth], m_ppcResiYuvTemp[uhDepth], m_ppcRecoYuvTemp[uhDepth], bSkipRes, bUseMRG); 2116 2146 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncEntropy.cpp
r231 r280 133 133 #endif 134 134 135 #if HHI_MPI 135 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 136 136 Void TEncEntropy::encodeSPS( TComSPS* pcSPS, Bool bIsDepth ) 137 137 { … … 489 489 } 490 490 491 #if HHI_INTER_VIEW_RESIDUAL_PRED 491 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 492 492 Void 493 493 TEncEntropy::encodeResPredFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiPUIdx, Bool bRD ) -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncEntropy.h
r210 r280 80 80 #endif 81 81 82 #if HHI_MPI 82 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 83 83 virtual Void codeSPS ( TComSPS* pcSPS, Bool bIsDepth ) = 0; 84 84 #else … … 246 246 #endif 247 247 // SPS 248 #if HHI_MPI 248 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 249 249 Void encodeSPS ( TComSPS* pcSPS, Bool bIsDepth ); 250 250 #else … … 270 270 Void encodeMergeFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiPUIdx ); 271 271 Void encodeMergeIndex ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiPUIdx, Bool bRD = false ); 272 #if HHI_INTER_VIEW_RESIDUAL_PRED 272 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 273 273 Void encodeResPredFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiPUIdx, Bool bRD = false ); 274 274 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncGOP.cpp
r231 r280 247 247 std::vector<TComAPS>& vAPS = m_pcEncTop->getAPS(); 248 248 #if VIDYO_VPS_INTEGRATION|QC_MVHEVC_B0046 249 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 250 m_pcSliceEncoder->initEncSlice ( pcPic, iPOCLast, uiPOCCurr, iNumPicRcvd, iGOPid, pcSlice, m_pcEncTop->getEncTop()->getVPS(), m_pcEncTop->getSPS(), m_pcEncTop->getPPS(), m_pcEncTop->getIsDepth() ); 251 #else 249 252 m_pcSliceEncoder->initEncSlice ( pcPic, iPOCLast, uiPOCCurr, iNumPicRcvd, iGOPid, pcSlice, m_pcEncTop->getEncTop()->getVPS(), m_pcEncTop->getSPS(), m_pcEncTop->getPPS() ); 253 #endif 250 254 #else 251 255 m_pcSliceEncoder->initEncSlice ( pcPic, iPOCLast, uiPOCCurr, iNumPicRcvd, iGOPid, pcSlice, m_pcEncTop->getSPS(), m_pcEncTop->getPPS() ); … … 255 259 pcSlice->setViewId( m_pcEncTop->getViewId() ); 256 260 pcSlice->setIsDepth( m_pcEncTop->getIsDepth() ); 261 #if INTER_VIEW_VECTOR_SCALING_C0115 262 pcSlice->setIVScalingFlag( m_pcEncTop->getUseIVS() ); 263 #endif 257 264 258 265 m_pcEncTop->getSPS()->setDisInter4x4(m_pcEncTop->getDisInter4x4()); … … 340 347 pcSlice->setNumRefIdx( REF_PIC_LIST_1, min( m_pcCfg->getGOPEntry( (getNalUnitType(uiPOCCurr) == NAL_UNIT_CODED_SLICE_IDV) ? MAX_GOP : iGOPid ).m_numRefPicsActive, (pcSlice->getRPS()->getNumberOfPictures() + pcSlice->getSPS()->getNumberOfUsableInterViewRefs()) ) ); 341 348 #else 349 342 350 Bool bNalRAP = ((getNalUnitType(uiPOCCurr) == NAL_UNIT_CODED_SLICE_CRA) || (getNalUnitType(uiPOCCurr) == NAL_UNIT_CODED_SLICE_IDR)) && (pcSlice->getSPS()->getViewId()) ? 1: 0; 343 351 pcSlice->setNumRefIdx( REF_PIC_LIST_0, min( m_pcCfg->getGOPEntry( bNalRAP ? MAX_GOP : iGOPid ).m_numRefPicsActive, (pcSlice->getRPS()->getNumberOfPictures() + pcSlice->getSPS()->getNumberOfUsableInterViewRefs()) ) ); 344 352 pcSlice->setNumRefIdx( REF_PIC_LIST_1, min( m_pcCfg->getGOPEntry( bNalRAP ? MAX_GOP : iGOPid ).m_numRefPicsActive, (pcSlice->getRPS()->getNumberOfPictures() + pcSlice->getSPS()->getNumberOfUsableInterViewRefs()) ) ); 345 353 #endif 346 347 354 TComRefPicListModification* refPicListModification = pcSlice->getRefPicListModification(); 348 355 refPicListModification->setRefPicListModificationFlagL0( false ); … … 906 913 pcSlice->getSPS()->setNumSubstreams( pcSlice->getPPS()->getNumSubstreams() ); 907 914 #endif 908 #if HHI_MPI 915 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 909 916 m_pcEntropyCoder->encodeSPS(pcSlice->getSPS(), m_pcEncTop->getIsDepth()); 910 917 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSbac.cpp
r231 r280 404 404 #endif 405 405 406 #if HHI_MPI 406 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 407 407 Void TEncSbac::codeSPS( TComSPS* pcSPS, Bool bIsDepth ) 408 408 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSbac.h
r210 r280 102 102 #endif 103 103 104 #if HHI_MPI 104 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 105 105 Void codeSPS ( TComSPS* pcSPS, Bool bIsDepth ); 106 106 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSearch.cpp
r275 r280 2947 2947 #else 2948 2948 #if LG_RESTRICTEDRESPRED_M24766 2949 #if MERL_VSP_C0152 2949 #if MERL_VSP_C0152 || MTK_MDIVRP_C0138 2950 #if !MTK_MDIVRP_C0138 2950 2951 Void TEncSearch::xMergeEstimation( TComDataCU* pcCU, TComYuv* pcYuvOrg, TComYuv* rpcResiPredYuv, Int iPUIdx, UInt& uiInterDir, TComMvField* pacMvField, UInt& uiMergeIndex, UInt& ruiCost, Int* iVSPIndexTrue ) 2952 #endif 2953 #if !MERL_VSP_C0152 2954 Void TEncSearch::xMergeEstimation( TComDataCU* pcCU, TComYuv* pcYuvOrg, Int iPUIdx, UInt& uiInterDir, TComMvField* pacMvField, UInt& uiMergeIndex, UInt& ruiCost ) 2955 #endif 2956 #if MERL_VSP_C0152 && MTK_MDIVRP_C0138 2957 Void TEncSearch::xMergeEstimation( TComDataCU* pcCU, TComYuv* pcYuvOrg, Int iPUIdx, UInt& uiInterDir, TComMvField* pacMvField, UInt& uiMergeIndex, UInt& ruiCost, Int* iVSPIndexTrue ) 2958 #endif 2951 2959 #else 2952 2960 Void TEncSearch::xMergeEstimation( TComDataCU* pcCU, TComYuv* pcYuvOrg, TComYuv* rpcResiPredYuv, Int iPUIdx, UInt& uiInterDir, TComMvField* pacMvField, UInt& uiMergeIndex, UInt& ruiCost ) … … 3007 3015 const int maxNumMergeCand = MRG_MAX_NUM_CANDS_SIGNALED + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 3008 3016 #endif 3009 #if LG_RESTRICTEDRESPRED_M24766 3017 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3010 3018 Int iPUResiPredShift[4]; 3011 3019 Int iLastAddResiShift = -1000; … … 3038 3046 } 3039 3047 #endif 3040 #if LG_RESTRICTEDRESPRED_M24766 3048 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3041 3049 Int iAddResiShift; 3042 3050 UInt uiPartAddr; … … 3088 3096 } 3089 3097 } 3090 #if LG_RESTRICTEDRESPRED_M24766 3098 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3091 3099 if( pcCU->getResPredFlag( 0 ) && iLastAddResiShift >= 0) 3092 3100 { … … 3107 3115 */ 3108 3116 #if AMP_MRG 3109 #if LG_RESTRICTEDRESPRED_M24766 3117 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3110 3118 Void TEncSearch::predInterSearch( TComDataCU* pcCU, TComYuv* pcOrgYuv, TComYuv* rpcResiPredYuv, TComYuv*& rpcPredYuv, TComYuv*& rpcResiYuv, TComYuv*& rpcRecoYuv, Bool bUseRes, Bool bUseMRG ) 3111 3119 #else … … 3214 3222 for (Int iNumRef=0; iNumRef < MAX_NUM_REF; iNumRef++) uiCostTempL0[iNumRef] = MAX_UINT; 3215 3223 UInt uiBitsTempL0[MAX_NUM_REF]; 3216 3217 #if LG_RESTRICTEDRESPRED_M24766 3224 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3218 3225 Int iPUResiPredShift[4] = {0, 0, 0, 0}; 3219 3226 #endif … … 3236 3243 { 3237 3244 #endif 3238 #if LG_RESTRICTEDRESPRED_M24766 3245 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3239 3246 Bool bLastResiFlag = false; 3240 3247 #endif … … 3247 3254 for ( Int iRefIdxTemp = 0; iRefIdxTemp < pcCU->getSlice()->getNumRefIdx(eRefPicList); iRefIdxTemp++ ) 3248 3255 { 3249 #if LG_RESTRICTEDRESPRED_M24766 3256 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3250 3257 if( pcCU->getResPredFlag( 0 )) 3251 3258 { … … 3435 3442 } 3436 3443 } 3437 #if LG_RESTRICTEDRESPRED_M24766 3444 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3438 3445 if( pcCU->getResPredFlag( 0 ) && bLastResiFlag) 3439 3446 { // subtract residual prediction from original in motion search … … 3444 3451 if ( pcCU->getSlice()->isInterB() ) 3445 3452 { 3446 #if LG_RESTRICTEDRESPRED_M24766 3453 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3447 3454 Int iLastAddResiShift = -1000; 3448 3455 #endif … … 3552 3559 uiBitsTemp += m_auiMVPIdxCost[aaiMvpIdxBi[iRefList][iRefIdxTemp]][AMVP_MAX_NUM_CANDS]; 3553 3560 #endif 3554 #if LG_RESTRICTEDRESPRED_M24766 3561 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3555 3562 Int iAddResiShift = -1, iPredFrom = 0; 3556 3563 Int iBestRefIdx = pcCU->getCUMvField(eRefPicList == REF_PIC_LIST_0 ? REF_PIC_LIST_1 : REF_PIC_LIST_0)->getRefIdx(uiPartAddr); … … 3641 3648 } 3642 3649 } // for loop-iter 3643 #if LG_RESTRICTEDRESPRED_M24766 3650 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3644 3651 if( pcCU->getResPredFlag( 0 ) && iLastAddResiShift >= 0) 3645 3652 { … … 3856 3863 if (bTestNormalMC) 3857 3864 { 3858 #if LG_RESTRICTEDRESPRED_M24766 3865 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3859 3866 Int iAddResiShift = pcCU->getResiPredMode(uiPartAddr); 3860 3867 iPUResiPredShift[0] = iPUResiPredShift[1] = iPUResiPredShift[2] = iPUResiPredShift[3] = \ … … 3867 3874 xGetInterPredictionError( pcCU, pcOrgYuv, iPartIdx, uiMEError, m_pcEncCfg->getUseHADME() ); 3868 3875 uiMECost = uiMEError + m_pcRdCost->getCost( uiMEBits ); 3869 #if LG_RESTRICTEDRESPRED_M24766 3876 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 3870 3877 if(pcCU->getResPredFlag(0) && iAddResiShift >= 0) 3871 3878 { … … 3895 3902 #else 3896 3903 #if LG_RESTRICTEDRESPRED_M24766 3897 #if MERL_VSP_C0152 3904 #if MERL_VSP_C0152 || MTK_MDIVRP_C0138 3905 3906 #if !MTK_MDIVRP_C0138 3898 3907 xMergeEstimation( pcCU, pcOrgYuv, rpcResiPredYuv, iPartIdx, uiMRGInterDir, cMRGMvField, uiMRGIndex, uiMRGCost, iVSPIndexTrue ); 3908 #endif 3909 3910 #if !MERL_VSP_C0152 3911 xMergeEstimation( pcCU, pcOrgYuv, iPartIdx, uiMRGInterDir, cMRGMvField, uiMRGIndex, uiMRGCost ); 3912 #endif 3913 3914 #if MERL_VSP_C0152 && MTK_MDIVRP_C0138 3915 xMergeEstimation( pcCU, pcOrgYuv, iPartIdx, uiMRGInterDir, cMRGMvField, uiMRGIndex, uiMRGCost, iVSPIndexTrue ); 3916 #endif 3917 3899 3918 #else 3900 3919 xMergeEstimation( pcCU, pcOrgYuv, rpcResiPredYuv, iPartIdx, uiMRGInterDir, cMRGMvField, uiMRGIndex, uiMRGCost ); 3901 3920 #endif 3921 3922 3902 3923 #else 3903 3924 xMergeEstimation( pcCU, pcOrgYuv, iPartIdx, uiMRGInterDir, cMRGMvField, uiMRGIndex, uiMRGCost ); … … 4833 4854 UInt uiWidth = pcCU->getWidth ( 0 ); 4834 4855 UInt uiHeight = pcCU->getHeight( 0 ); 4835 #if LG_RESTRICTEDRESPRED_M24766 4856 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 4836 4857 Int iPUResiPredShift[4]; 4837 4858 #endif 4838 4859 // No residual coding : SKIP mode 4839 if ( (ePredMode == MODE_SKIP && bSkipRes))4860 if ( ePredMode == MODE_SKIP && bSkipRes ) 4840 4861 { 4841 4862 rpcYuvResi->clear(); … … 4843 4864 pcYuvPred->copyToPartYuv( rpcYuvRec, 0 ); 4844 4865 4866 #if MTK_MDIVRP_C0138 4867 if (pcCU->getMergeFlag(0) && pcCU->getMergeIndex(0)==0 && pcCU->getResPredAvail(0)) 4868 { 4869 rpcYuvRec->clip( uiWidth, uiHeight ); 4870 } 4871 #else 4845 4872 #if HHI_INTER_VIEW_RESIDUAL_PRED 4846 4873 // add residual prediction … … 4855 4882 rpcYuvRec->clip( uiWidth, uiHeight ); 4856 4883 } 4884 #endif 4857 4885 #endif 4858 4886 … … 4900 4928 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true); 4901 4929 #endif 4902 #if HHI_INTER_VIEW_RESIDUAL_PRED 4930 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 4903 4931 m_pcEntropyCoder->encodeResPredFlag( pcCU, 0, 0, true ); 4904 4932 #endif … … 4978 5006 else 4979 5007 { 4980 #if LG_RESTRICTEDRESPRED_M24766 5008 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 4981 5009 iPUResiPredShift[0] = iPUResiPredShift[1] = iPUResiPredShift[2] = iPUResiPredShift[3] = 0; 4982 5010 rpcYuvResi->subtract(iPUResiPredShift, pcCU->getPartitionSize(0), pcYuvOrg, pcYuvPred, 0, uiWidth ); … … 4984 5012 rpcYuvResi->subtract( pcYuvOrg, pcYuvPred, 0, uiWidth ); 4985 5013 #endif 4986 #if HHI_INTER_VIEW_RESIDUAL_PRED 5014 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 4987 5015 // subtract residual prediction 4988 5016 if( pcCU->getResPredFlag( 0 ) ) … … 5206 5234 #endif 5207 5235 } 5208 #if HHI_INTER_VIEW_RESIDUAL_PRED 5236 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 5209 5237 // add residual prediction 5210 5238 if( pcCU->getResPredFlag( 0 ) ) … … 6283 6311 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true); 6284 6312 #endif 6285 #if HHI_INTER_VIEW_RESIDUAL_PRED 6313 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 6286 6314 m_pcEntropyCoder->encodeResPredFlag( pcCU, 0, 0, true ); 6287 6315 #endif … … 6306 6334 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true); 6307 6335 #endif 6308 #if HHI_INTER_VIEW_RESIDUAL_PRED 6336 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 6309 6337 m_pcEntropyCoder->encodeResPredFlag( pcCU, 0, 0, true ); 6310 6338 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSearch.h
r231 r280 196 196 Void predInterSearch ( TComDataCU* pcCU, 197 197 TComYuv* pcOrgYuv, 198 #if LG_RESTRICTEDRESPRED_M24766 198 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 199 199 TComYuv* rpcResiPredYuv, 200 200 #endif … … 500 500 Void xMergeEstimation ( TComDataCU* pcCU, 501 501 TComYuv* pcYuvOrg, 502 #if LG_RESTRICTEDRESPRED_M24766 502 #if LG_RESTRICTEDRESPRED_M24766 && !MTK_MDIVRP_C0138 503 503 TComYuv* rpcResiPredYuv, 504 504 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSlice.cpp
r231 r280 163 163 */ 164 164 #if VIDYO_VPS_INTEGRATION|QC_MVHEVC_B0046 165 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 166 Void TEncSlice::initEncSlice( TComPic* pcPic, Int iPOCLast, UInt uiPOCCurr, Int iNumPicRcvd, Int iGOPid, TComSlice*& rpcSlice, TComVPS * pVPS, TComSPS* pSPS, TComPPS *pPPS, bool isDepth ) 167 #else 165 168 Void TEncSlice::initEncSlice( TComPic* pcPic, Int iPOCLast, UInt uiPOCCurr, Int iNumPicRcvd, Int iGOPid, TComSlice*& rpcSlice, TComVPS * pVPS, TComSPS* pSPS, TComPPS *pPPS ) 169 #endif 166 170 #else 167 171 Void TEncSlice::initEncSlice( TComPic* pcPic, Int iPOCLast, UInt uiPOCCurr, Int iNumPicRcvd, Int iGOPid, TComSlice*& rpcSlice, TComSPS* pSPS, TComPPS *pPPS ) … … 186 190 rpcSlice->setPOC( uiPOCCurr ); 187 191 188 #if SONY_COLPIC_AVAILABILITY189 rpcSlice->setViewOrderIdx(m_pcCfg->getViewOrderIdx()); 192 #if INTER_VIEW_VECTOR_SCALING_C0115 193 rpcSlice->setViewOrderIdx(m_pcCfg->getViewOrderIdx()); // will be changed to view_id 190 194 #endif 191 195 #if LGE_ILLUCOMP_B0045 … … 470 474 #elif HHI_MPI 471 475 const int iExtraMergeCandidates = pSPS->getUseMVI() ? 1 : 0; 476 #elif MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 477 const int iExtraMergeCandidates = ( isDepth || pSPS->getMultiviewMvPredMode() ) ? 1 : 0; 472 478 #else 473 479 const int iExtraMergeCandidates = pSPS->getMultiviewMvPredMode() ? 1 : 0; -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSlice.h
r231 r280 120 120 /// preparation of slice encoding (reference marking, QP and lambda) 121 121 #if VIDYO_VPS_INTEGRATION|QC_MVHEVC_B0046 122 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 123 Void initEncSlice ( TComPic* pcPic, Int iPOCLast, UInt uiPOCCurr, Int iNumPicRcvd, Int iGOPid, TComSlice*& rpcSlice, TComVPS* pVPS, TComSPS* pSPS, TComPPS *pPPS, bool isDepth ); 124 #else 122 125 Void initEncSlice ( TComPic* pcPic, Int iPOCLast, UInt uiPOCCurr, Int iNumPicRcvd, Int iGOPid, TComSlice*& rpcSlice, TComVPS* pVPS, TComSPS* pSPS, TComPPS *pPPS ); 126 #endif 123 127 #else 124 128 Void initEncSlice ( TComPic* pcPic, Int iPOCLast, UInt uiPOCCurr, Int iNumPicRcvd, Int iGOPid, TComSlice*& rpcSlice, TComSPS* pSPS, TComPPS *pPPS ); -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncTop.cpp
r210 r280 404 404 pcPicYuvOrg->copyToPic( pcPicCurr->getPicYuvOrg() ); 405 405 406 #if SONY_COLPIC_AVAILABILITY407 pcPicCurr->setViewOrderIdx(m_iViewOrderIdx); 406 #if INTER_VIEW_VECTOR_SCALING_C0115 407 pcPicCurr->setViewOrderIdx(m_iViewOrderIdx); // will be changed to view_id 408 408 #endif 409 409 pcPicCurr->setScaleOffset( m_aaiCodedScale, m_aaiCodedOffset ); -
branches/HTM-5.1-dev0/source/Lib/TLibExtractor/TExtrTop.cpp
r210 r280 81 81 cSPS.setRPSList( &cRPS ); 82 82 #endif 83 #if HHI_MPI 83 #if HHI_MPI || OL_QTLIMIT_PREDCODING_B0068 84 84 #if VIDYO_VPS_INTEGRATION 85 85 m_cEntropyDecoder.decodeSPS( &cSPS, m_cVPS.getDepthFlag(uiLayerId) );
Note: See TracChangeset for help on using the changeset viewer.