Changeset 292 in 3DVCSoftware for branches/HTM-5.1-dev0/source
- Timestamp:
- 19 Feb 2013, 17:50:51 (12 years ago)
- Location:
- branches/HTM-5.1-dev0/source
- Files:
-
- 37 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncCfg.cpp
r287 r292 398 398 ("PredDepthMapGen", m_uiPredDepthMapGeneration, (UInt)0, "generation of prediction depth maps for motion data prediction" ) 399 399 #endif 400 #if H HI_INTER_VIEW_MOTION_PRED400 #if H3D_IVMP 401 401 ("MultiviewMvPred", m_uiMultiviewMvPredMode, (UInt)0, "usage of predicted depth maps" ) 402 402 ("MultiviewMvRegMode", m_uiMultiviewMvRegMode, (UInt)0, "regularization mode for multiview motion vectors" ) … … 974 974 xConfirmPara ( m_uiPredDepthMapGeneration >= 2 && !m_bUsingDepthMaps, "PredDepthMapGen >= 2 requires CodeDepthMaps = 1" ); 975 975 #endif 976 #if H HI_INTER_VIEW_MOTION_PRED976 #if H3D_IVMP 977 977 xConfirmPara ( m_uiMultiviewMvPredMode > 7, "MultiviewMvPred must be less than or equal to 7" ); 978 978 xConfirmPara ( m_uiMultiviewMvPredMode > 0 && m_uiPredDepthMapGeneration == 0 , "MultiviewMvPred > 0 requires PredDepthMapGen > 0" ); -
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncCfg.h
r287 r292 233 233 UInt m_uiPredDepthMapGeneration; ///< using of (virtual) depth maps for texture coding 234 234 #endif 235 #if H HI_INTER_VIEW_MOTION_PRED235 #if H3D_IVMP 236 236 UInt m_uiMultiviewMvPredMode; ///< usage of predictors for multi-view mv prediction 237 237 UInt m_uiMultiviewMvRegMode; ///< regularization for multiview motion vectors -
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncTop.cpp
r289 r292 235 235 m_acTEncTopList[iViewIdx]->setPdmOffset ( m_cCameraData.getPdmOffset () ); 236 236 #endif 237 #if H HI_INTER_VIEW_MOTION_PRED237 #if H3D_IVMP 238 238 m_acTEncTopList[iViewIdx]->setMultiviewMvPredMode ( m_uiMultiviewMvPredMode ); 239 239 m_acTEncTopList[iViewIdx]->setMultiviewMvRegMode ( iViewIdx ? m_uiMultiviewMvRegMode : 0 ); … … 605 605 m_acTEncDepthTopList[iViewIdx]->setPredDepthMapGeneration ( 0 ); 606 606 #endif 607 #if H HI_INTER_VIEW_MOTION_PRED607 #if H3D_IVMP 608 608 m_acTEncDepthTopList[iViewIdx]->setMultiviewMvPredMode ( 0 ); 609 609 m_acTEncDepthTopList[iViewIdx]->setMultiviewMvRegMode ( 0 ); … … 741 741 } 742 742 743 #if H HI_INTER_VIEW_MOTION_PRED743 #if H3D_IVMP 744 744 else if( m_uiMultiviewMvRegMode ) 745 745 { … … 828 828 m_acTEncDepthTopList[iViewIdx]->create(); 829 829 } 830 #if H HI_INTER_VIEW_MOTION_PRED830 #if H3D_IVMP 831 831 else if( m_uiMultiviewMvRegMode ) 832 832 { … … 975 975 pcDepthPicYuvOrg->create( m_iSourceWidth, m_iSourceHeight, m_uiMaxCUWidth, m_uiMaxCUHeight, m_uiMaxCUDepth ); 976 976 977 #if H HI_INTER_VIEW_MOTION_PRED977 #if H3D_IVMP 978 978 if( m_uiMultiviewMvRegMode ) 979 979 { … … 995 995 m_acTVideoIOYuvInputFileList[iViewIdx]->read( pcPicYuvOrg, m_aiPad ); 996 996 997 #if H HI_INTER_VIEW_MOTION_PRED997 #if H3D_IVMP 998 998 if( m_uiMultiviewMvRegMode && iViewIdx ) 999 999 { … … 1002 1002 #endif 1003 1003 1004 #if H HI_INTER_VIEW_MOTION_PRED1004 #if H3D_IVMP 1005 1005 m_acTEncTopList[iViewIdx]->initNewPic( pcPicYuvOrg, ( m_uiMultiviewMvRegMode && iViewIdx ? pcPdmDepthOrg : 0 ) ); 1006 1006 #else … … 1151 1151 #endif 1152 1152 1153 #if HHI_INTERVIEW_SKIP || H HI_INTER_VIEW_MOTION_PRED|| HHI_INTER_VIEW_RESIDUAL_PRED1153 #if HHI_INTERVIEW_SKIP || H3D_IVMP || HHI_INTER_VIEW_RESIDUAL_PRED 1154 1154 for( Int iViewIdx = 0; iViewIdx < m_iNumberOfViews; iViewIdx++ ) 1155 1155 { -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/CommonDef.h
r289 r292 128 128 #define MAX_VIEW_NUM 10 129 129 130 #if ( H HI_INTER_VIEW_MOTION_PRED|| HHI_INTER_VIEW_RESIDUAL_PRED )130 #if ( H3D_IVMP || HHI_INTER_VIEW_RESIDUAL_PRED ) 131 131 #define DEPTH_MAP_GENERATION 1 132 132 #define PDM_REMOVE_DEPENDENCE 1 //bug-fix for DMDV JCT2-A0095 … … 140 140 #define PDM_MERGE_POS 0 // position of pdm in merge list (0..4) 141 141 142 #if QC_MRG_CANS_B0048 143 #if OL_DISMV_POS_B0069 142 #if H3D_IVMP 144 143 #define DMV_MERGE_POS 4 145 144 #else 146 145 #define DMV_MERGE_POS 1 147 146 #endif 148 #endif 149 150 #if SAIT_IMPROV_MOTION_PRED_M24829&!H3D_NBDV 147 148 #if H3D_IVMP&!H3D_NBDV 151 149 #define PDM_AMVP_POS 0 // position of pdm in amvp list (0..3) 152 150 #else … … 424 422 // AMVP: advanced motion vector prediction 425 423 #define AMVP_MAX_NUM_CANDS 2 ///< max number of final candidates 426 #if H HI_INTER_VIEW_MOTION_PRED424 #if H3D_IVMP 427 425 #define AMVP_MAX_NUM_CANDS_MEM 4 ///< max number of candidates 428 426 #else … … 431 429 // MERGE 432 430 #define MRG_MAX_NUM_CANDS 5 433 #if H HI_INTER_VIEW_MOTION_PRED431 #if H3D_IVMP 434 432 #define MRG_MAX_NUM_CANDS_MEM (MRG_MAX_NUM_CANDS+1) // one extra for inter-view motion prediction 435 433 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDataCU.cpp
r291 r292 3842 3842 #endif 3843 3843 { 3844 #if H HI_INTER_VIEW_MOTION_PRED3844 #if H3D_IVMP 3845 3845 #if MTK_DEPTH_MERGE_TEXTURE_CANDIDATE_C0137 3846 3846 const Int extraMergeCand = ( ( getSlice()->getIsDepth() || getSlice()->getSPS()->getMultiviewMvPredMode() )? 1 : 0 ); … … 3852 3852 UInt uiAbsPartAddr = m_uiAbsIdxInLCU + uiAbsPartIdx; 3853 3853 UInt uiIdx = 1; 3854 #if H HI_INTER_VIEW_MOTION_PRED3854 #if H3D_IVMP 3855 3855 Bool abCandIsInter[ MRG_MAX_NUM_CANDS_MEM ]; 3856 3856 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS_MEM; ++ui ) … … 3927 3927 #endif 3928 3928 3929 #if H HI_INTER_VIEW_MOTION_PRED3929 #if H3D_IVMP 3930 3930 Bool bNoPdmMerge = ( m_pcSlice->getSPS()->getViewId() == 0 || ( m_pcSlice->getSPS()->getMultiviewMvPredMode() & PDM_USE_FOR_MERGE ) != PDM_USE_FOR_MERGE ); 3931 3931 3932 3932 //===== add merge with predicted depth maps ===== 3933 #if QC_MRG_CANS_B00483934 3933 TComMv acPdmMv [4]; 3935 3934 Int aiPdmRefIdx [4] = {-1, -1, -1, -1}; 3936 3935 Bool bLeftAvai = false; 3937 #if OL_DISMV_POS_B00693938 3936 Int iPosLeftAbove[2] = {-1, -1}; 3939 #endif3940 #else3941 TComMv acPdmMv [2];3942 Int aiPdmRefIdx [2] = {-1, -1};3943 #endif3944 3937 3945 3938 #if H3D_NBDV 3946 #if QC_MRG_CANS_B00483947 3939 acPdmMv[0].m_bDvMcp = acPdmMv[1].m_bDvMcp = acPdmMv[2].m_bDvMcp = acPdmMv[3].m_bDvMcp = false; 3948 #else3949 acPdmMv[0].m_bDvMcp = acPdmMv[1].m_bDvMcp = false;3950 #endif3951 3940 #endif //H3D_NBDV 3952 3941 … … 4024 4013 #endif 4025 4014 #endif 4026 #if QC_MRG_CANS_B00484027 4015 Int iPdmDir[2] = {0, 0}; 4028 #endif4029 4016 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 4030 4017 getUnifiedMvPredCan(uiPUIdx, REF_PIC_LIST_0, 0, aiPdmRefIdx, acPdmMv, &cDisInfo, iPdmDir, true); 4031 4018 Int iPdmInterDir; 4032 4019 #else 4033 Int iPdmInterDir = cDisInfo.iN==0? 0:getPdmMergeCandidateDisCan ( uiPUIdx, aiPdmRefIdx, acPdmMv, &cDisInfo 4034 #if QC_MRG_CANS_B0048 4035 , iPdmDir 4036 #endif 4037 ); 4020 Int iPdmInterDir = cDisInfo.iN==0? 0:getPdmMergeCandidateDisCan ( uiPUIdx, aiPdmRefIdx, acPdmMv, &cDisInfo, iPdmDir ); 4038 4021 #endif 4039 4022 #else // H3D_NBDV … … 4050 4033 #endif 4051 4034 4052 #if QC_MRG_CANS_B00484053 4035 if( iPdmDir[0] && !bNoPdmMerge && PDM_MERGE_POS == 0 ) 4054 #else4055 if( iPdmInterDir && !bNoPdmMerge && PDM_MERGE_POS == 0 )4056 #endif4057 4036 { 4058 4037 abCandIsInter [ iCount ] = true; 4059 #if QC_MRG_CANS_B00484060 4038 puhInterDirNeighbours[ iCount ] = iPdmDir[0]; 4061 4039 iPdmInterDir = iPdmDir[0]; 4062 #else 4063 puhInterDirNeighbours[ iCount ] = iPdmInterDir; 4064 #endif 4040 4065 4041 if( ( iPdmInterDir & 1 ) == 1 ) 4066 4042 { … … 4091 4067 iCount ++; 4092 4068 } 4093 #endif 4094 4095 #if QC_MRG_CANS_B0048 4069 4096 4070 if(extraMergeCand) 4097 4071 { … … 4120 4094 } 4121 4095 } 4122 #endif 4096 #endif // HHI_INTER_VIEW_MOTION_PRED 4123 4097 4124 4098 #if MERL_VSP_COMPENSATION_C0152 … … 4149 4123 if (!(uiPUIdx == 1 && (partSize == SIZE_Nx2N || partSize == SIZE_nLx2N || partSize == SIZE_nRx2N))) 4150 4124 { 4151 if ( pcCULeft && !pcCULeft->isIntra( uiLeftPartIdx )4125 if ( pcCULeft && !pcCULeft->isIntra( uiLeftPartIdx ) 4152 4126 #if MERL_VSP_C0152 4153 CHECK_ADD_YET(pcCULeft, uiLeftPartIdx, 1) 4154 #endif 4155 ) 4127 CHECK_ADD_YET(pcCULeft, uiLeftPartIdx, 1) 4128 #endif 4129 ) 4130 { 4131 abCandIsInter[iCount] = true; 4132 // get Inter Dir 4133 puhInterDirNeighbours[iCount] = pcCULeft->getInterDir( uiLeftPartIdx ); 4134 // get Mv from Left 4135 pcCULeft->getMvField( pcCULeft, uiLeftPartIdx, REF_PIC_LIST_0, pcMvFieldNeighbours[iCount<<1] ); 4136 if ( getSlice()->isInterB() ) 4137 { 4138 pcCULeft->getMvField( pcCULeft, uiLeftPartIdx, REF_PIC_LIST_1, pcMvFieldNeighbours[(iCount<<1)+1] ); 4139 } 4140 #if FIX_CU_BASED_MRG_CAND_LIST_B0136 4141 else 4142 { 4143 pcMvFieldNeighbours[(iCount<<1)+1 ].setMvField( TComMv(0,0), NOT_VALID ); 4144 } 4145 #endif 4146 4147 #if H3D_IVMP 4148 Bool bRemoveSpa = false; //pruning to inter-view candidates 4149 Int iCnloop = iCount - 1; 4150 for(; iCnloop >= 0; iCnloop --) 4151 { 4152 if(puhInterDirNeighbours[iCount] == puhInterDirNeighbours[iCnloop] && pcMvFieldNeighbours[iCnloop<<1]==pcMvFieldNeighbours[(iCount<<1)] && pcMvFieldNeighbours[(iCnloop<<1)+1]==pcMvFieldNeighbours[(iCount<<1)+1]) 4153 { 4154 bRemoveSpa = true; 4155 abCandIsInter [ iCount ] = false; 4156 4157 //reset to the default value for IC, MC 4158 puhInterDirNeighbours[iCount] = 0; 4159 TComMv cZeroMv; 4160 pcMvFieldNeighbours[iCount<<1].setMvField( cZeroMv, NOT_VALID ); 4161 pcMvFieldNeighbours[(iCount<<1)+1].setMvField( cZeroMv, NOT_VALID ); 4162 break; 4163 } 4164 } 4165 if(!bRemoveSpa) 4166 { 4167 bLeftAvai = true; 4168 iPosLeftAbove[0] = iCount; 4169 #endif //HHI_INTER_VIEW_MOTION_PRED 4170 #if H3D_NBDV 4171 pcMvFieldNeighbours[iCount<<1 ].getMv().m_bDvMcp = false; 4172 pcMvFieldNeighbours[(iCount<<1)+1].getMv().m_bDvMcp = false; 4173 #endif 4174 #if MERL_VSP_C0152 4175 xInheritVspMode( pcCULeft, uiLeftPartIdx, bVspMvZeroDone, iCount, iVSPIndexTrue, pcMvFieldNeighbours, &cDisInfo ) ; 4176 #endif 4177 #if SIMP_MRG_PRUN 4178 if ( mrgCandIdx == iCount ) 4179 { 4180 return; 4181 } 4182 #endif 4183 iCount ++; 4184 #if H3D_IVMP 4185 } 4186 #endif 4187 } 4188 } 4189 4190 #if H3D_IVMP 4191 if( iPdmDir[0] && !bNoPdmMerge && PDM_MERGE_POS == 1 ) 4192 { 4193 abCandIsInter [ iCount ] = true; 4194 puhInterDirNeighbours[ iCount ] = iPdmInterDir; 4195 if( ( iPdmInterDir & 1 ) == 1 ) 4196 { 4197 pcMvFieldNeighbours[ iCount<<1 ].setMvField( acPdmMv[ 0 ], aiPdmRefIdx[ 0 ] ); 4198 } 4199 #if FIX_CU_BASED_MRG_CAND_LIST_B0136 4200 else 4201 { 4202 pcMvFieldNeighbours[ iCount<<1 ].setMvField( TComMv(0,0), NOT_VALID ); 4203 } 4204 #endif 4205 if( ( iPdmInterDir & 2 ) == 2 ) 4206 { 4207 pcMvFieldNeighbours[(iCount<<1)+1 ].setMvField( acPdmMv[ 1 ], aiPdmRefIdx[ 1 ] ); 4208 } 4209 #if FIX_CU_BASED_MRG_CAND_LIST_B0136 4210 else 4211 { 4212 pcMvFieldNeighbours[(iCount<<1)+1 ].setMvField( TComMv(0,0), NOT_VALID ); 4213 } 4214 #endif 4215 #if SIMP_MRG_PRUN 4216 if ( mrgCandIdx == iCount ) 4217 { 4218 return; 4219 } 4220 #endif 4221 iCount ++; 4222 } 4223 #endif // HHI_INTER_VIEW_MOTION_PRED 4224 4225 #if MERL_VSP_COMPENSATION_C0152 4226 //===== vsp 1 ===== 4227 if( iCount < 4 + extraMergeCand ) 4228 if ( !xAddVspMergeCand(1, 1, bVspMvZeroDone, uiDepth, abCandIsInter, iCount, puhInterDirNeighbours, pcMvFieldNeighbours, iVSPIndexTrue, mrgCandIdx, &cDisInfo) ) 4229 return; 4230 #endif 4231 4232 // above 4233 #if !SIMP_MRG_PRUN 4234 partSize = getPartitionSize( uiAbsPartIdx ); 4235 if (!(uiPUIdx == 1 && (partSize == SIZE_2NxN || partSize == SIZE_2NxnU || partSize == SIZE_2NxnD))) 4236 { 4237 #endif 4238 UInt uiAbovePartIdx = 0; 4239 TComDataCU* pcCUAbove = 0; 4240 #if MVP_AT_ENTROPYSLICE_BOUNDARY 4241 pcCUAbove = getPUAbove( uiAbovePartIdx, uiPartIdxRT, true, false, true ); 4242 #else 4243 pcCUAbove = getPUAbove( uiAbovePartIdx, uiPartIdxRT, true, true, true ); 4244 #endif 4245 #if PARALLEL_MERGE 4246 if (pcCUAbove) 4247 { 4248 if (!pcCUAbove->isDiffMER(xP+nPSW-1, yP-1, xP, yP)) 4249 { 4250 pcCUAbove = NULL; 4251 } 4252 } 4253 #endif 4254 #if SIMP_MRG_PRUN 4255 if ( pcCUAbove && !pcCUAbove->isIntra( uiAbovePartIdx ) 4256 #if MERL_VSP_C0152 4257 CHECK_ADD_YET(pcCUAbove, uiAbovePartIdx, 1) 4258 #endif 4259 && !(uiPUIdx == 1 && (cCurPS == SIZE_2NxN || cCurPS == SIZE_2NxnU || cCurPS == SIZE_2NxnD)) 4260 && ( !pcCULeft || pcCULeft->isIntra( uiLeftPartIdx ) || !pcCULeft->hasEqualMotion( uiLeftPartIdx, pcCUAbove, uiAbovePartIdx ) ) ) 4261 #else 4262 if ( pcCUAbove && !pcCUAbove->isIntra( uiAbovePartIdx ) ) 4263 #endif 4156 4264 { 4157 4265 abCandIsInter[iCount] = true; 4158 4266 // get Inter Dir 4159 puhInterDirNeighbours[iCount] = pcCU Left->getInterDir( uiLeftPartIdx );4267 puhInterDirNeighbours[iCount] = pcCUAbove->getInterDir( uiAbovePartIdx ); 4160 4268 // get Mv from Left 4161 pcCU Left->getMvField( pcCULeft, uiLeftPartIdx, REF_PIC_LIST_0, pcMvFieldNeighbours[iCount<<1] );4269 pcCUAbove->getMvField( pcCUAbove, uiAbovePartIdx, REF_PIC_LIST_0, pcMvFieldNeighbours[iCount<<1] ); 4162 4270 if ( getSlice()->isInterB() ) 4163 4271 { 4164 pcCU Left->getMvField( pcCULeft, uiLeftPartIdx, REF_PIC_LIST_1, pcMvFieldNeighbours[(iCount<<1)+1] );4272 pcCUAbove->getMvField( pcCUAbove, uiAbovePartIdx, REF_PIC_LIST_1, pcMvFieldNeighbours[(iCount<<1)+1] ); 4165 4273 } 4166 4274 #if FIX_CU_BASED_MRG_CAND_LIST_B0136 … … 4170 4278 } 4171 4279 #endif 4172 #if QC_MRG_CANS_B00484280 #if H3D_IVMP 4173 4281 Bool bRemoveSpa = false; //prunign to inter-view candidates 4174 Int iCnloop = iCount - 1;4282 Int iCnloop = bLeftAvai? (iCount-2): (iCount-1); 4175 4283 for(; iCnloop >= 0; iCnloop --) 4176 4284 { … … 4190 4298 if(!bRemoveSpa) 4191 4299 { 4192 bLeftAvai = true; 4193 #if OL_DISMV_POS_B0069 4194 iPosLeftAbove[0] = iCount; 4195 #endif 4196 #endif 4300 iPosLeftAbove[1] = iCount; 4301 #endif // HHI_INTER_VIEW_MOTION_PRED 4197 4302 #if H3D_NBDV 4198 4303 pcMvFieldNeighbours[iCount<<1 ].getMv().m_bDvMcp = false; … … 4200 4305 #endif 4201 4306 #if MERL_VSP_C0152 4202 xInheritVspMode( pcCU Left, uiLeftPartIdx, bVspMvZeroDone, iCount, iVSPIndexTrue, pcMvFieldNeighbours, &cDisInfo ) ;4307 xInheritVspMode( pcCUAbove, uiAbovePartIdx, bVspMvZeroDone, iCount, iVSPIndexTrue, pcMvFieldNeighbours, &cDisInfo ) ; 4203 4308 #endif 4204 4309 #if SIMP_MRG_PRUN … … 4209 4314 #endif 4210 4315 iCount ++; 4211 #if QC_MRG_CANS_B0048 4212 } 4213 #endif 4214 } 4215 } 4216 4217 #if HHI_INTER_VIEW_MOTION_PRED 4218 #if QC_MRG_CANS_B0048 4219 if( iPdmDir[0] && !bNoPdmMerge && PDM_MERGE_POS == 1 ) 4220 #else 4221 if( iPdmInterDir && !bNoPdmMerge && PDM_MERGE_POS == 1 ) 4222 #endif 4316 #if H3D_IVMP 4317 } 4318 #endif 4319 } 4320 #if !SIMP_MRG_PRUN 4321 } 4322 #endif 4323 4324 #if H3D_IVMP 4325 if( iPdmDir[0] && !bNoPdmMerge && PDM_MERGE_POS == 2 ) 4223 4326 { 4224 4327 abCandIsInter [ iCount ] = true; … … 4252 4355 iCount ++; 4253 4356 } 4254 #endif 4255 4256 #if MERL_VSP_COMPENSATION_C0152 4257 //===== vsp 1 ===== 4258 if( iCount < 4 + extraMergeCand ) 4259 if ( !xAddVspMergeCand(1, 1, bVspMvZeroDone, uiDepth, abCandIsInter, iCount, puhInterDirNeighbours, pcMvFieldNeighbours, iVSPIndexTrue, mrgCandIdx, &cDisInfo) ) 4260 return; 4261 #endif 4262 4263 // above 4264 #if !SIMP_MRG_PRUN 4265 partSize = getPartitionSize( uiAbsPartIdx ); 4266 if (!(uiPUIdx == 1 && (partSize == SIZE_2NxN || partSize == SIZE_2NxnU || partSize == SIZE_2NxnD))) 4267 { 4268 #endif 4269 UInt uiAbovePartIdx = 0; 4270 TComDataCU* pcCUAbove = 0; 4271 #if MVP_AT_ENTROPYSLICE_BOUNDARY 4272 pcCUAbove = getPUAbove( uiAbovePartIdx, uiPartIdxRT, true, false, true ); 4273 #else 4274 pcCUAbove = getPUAbove( uiAbovePartIdx, uiPartIdxRT, true, true, true ); 4275 #endif 4276 #if PARALLEL_MERGE 4277 if (pcCUAbove) 4278 { 4279 if (!pcCUAbove->isDiffMER(xP+nPSW-1, yP-1, xP, yP)) 4280 { 4281 pcCUAbove = NULL; 4282 } 4283 } 4284 #endif 4285 #if SIMP_MRG_PRUN 4286 if ( pcCUAbove && !pcCUAbove->isIntra( uiAbovePartIdx ) 4287 #if MERL_VSP_C0152 4288 CHECK_ADD_YET(pcCUAbove, uiAbovePartIdx, 1) 4289 #endif 4290 && !(uiPUIdx == 1 && (cCurPS == SIZE_2NxN || cCurPS == SIZE_2NxnU || cCurPS == SIZE_2NxnD)) 4291 && ( !pcCULeft || pcCULeft->isIntra( uiLeftPartIdx ) || !pcCULeft->hasEqualMotion( uiLeftPartIdx, pcCUAbove, uiAbovePartIdx ) ) ) 4292 #else 4293 if ( pcCUAbove && !pcCUAbove->isIntra( uiAbovePartIdx ) ) 4294 #endif 4295 { 4296 abCandIsInter[iCount] = true; 4297 // get Inter Dir 4298 puhInterDirNeighbours[iCount] = pcCUAbove->getInterDir( uiAbovePartIdx ); 4299 // get Mv from Left 4300 pcCUAbove->getMvField( pcCUAbove, uiAbovePartIdx, REF_PIC_LIST_0, pcMvFieldNeighbours[iCount<<1] ); 4301 if ( getSlice()->isInterB() ) 4302 { 4303 pcCUAbove->getMvField( pcCUAbove, uiAbovePartIdx, REF_PIC_LIST_1, pcMvFieldNeighbours[(iCount<<1)+1] ); 4304 } 4305 #if FIX_CU_BASED_MRG_CAND_LIST_B0136 4306 else 4307 { 4308 pcMvFieldNeighbours[(iCount<<1)+1 ].setMvField( TComMv(0,0), NOT_VALID ); 4309 } 4310 #endif 4311 #if QC_MRG_CANS_B0048 4312 Bool bRemoveSpa = false; //prunign to inter-view candidates 4313 Int iCnloop = bLeftAvai? (iCount-2): (iCount-1); 4314 for(; iCnloop >= 0; iCnloop --) 4315 { 4316 if(puhInterDirNeighbours[iCount] == puhInterDirNeighbours[iCnloop] && pcMvFieldNeighbours[iCnloop<<1]==pcMvFieldNeighbours[(iCount<<1)] && pcMvFieldNeighbours[(iCnloop<<1)+1]==pcMvFieldNeighbours[(iCount<<1)+1]) 4317 { 4318 bRemoveSpa = true; 4319 abCandIsInter [ iCount ] = false; 4320 4321 //reset to the default value for IC, MC 4322 puhInterDirNeighbours[iCount] = 0; 4323 TComMv cZeroMv; 4324 pcMvFieldNeighbours[iCount<<1].setMvField( cZeroMv, NOT_VALID ); 4325 pcMvFieldNeighbours[(iCount<<1)+1].setMvField( cZeroMv, NOT_VALID ); 4326 break; 4327 } 4328 } 4329 if(!bRemoveSpa) 4330 { 4331 #if OL_DISMV_POS_B0069 4332 iPosLeftAbove[1] = iCount; 4333 #endif 4334 #endif 4335 #if H3D_NBDV 4336 pcMvFieldNeighbours[iCount<<1 ].getMv().m_bDvMcp = false; 4337 pcMvFieldNeighbours[(iCount<<1)+1].getMv().m_bDvMcp = false; 4338 #endif 4339 #if MERL_VSP_C0152 4340 xInheritVspMode( pcCUAbove, uiAbovePartIdx, bVspMvZeroDone, iCount, iVSPIndexTrue, pcMvFieldNeighbours, &cDisInfo ) ; 4341 #endif 4342 #if SIMP_MRG_PRUN 4343 if ( mrgCandIdx == iCount ) 4344 { 4345 return; 4346 } 4347 #endif 4348 iCount ++; 4349 #if QC_MRG_CANS_B0048 4350 } 4351 #endif 4352 } 4353 #if !SIMP_MRG_PRUN 4354 } 4355 #endif 4356 4357 #if HHI_INTER_VIEW_MOTION_PRED 4358 #if QC_MRG_CANS_B0048 4359 if( iPdmDir[0] && !bNoPdmMerge && PDM_MERGE_POS == 2 ) 4360 #else 4361 if( iPdmInterDir && !bNoPdmMerge && PDM_MERGE_POS == 2 ) 4362 #endif 4363 { 4364 abCandIsInter [ iCount ] = true; 4365 puhInterDirNeighbours[ iCount ] = iPdmInterDir; 4366 if( ( iPdmInterDir & 1 ) == 1 ) 4367 { 4368 pcMvFieldNeighbours[ iCount<<1 ].setMvField( acPdmMv[ 0 ], aiPdmRefIdx[ 0 ] ); 4369 } 4370 #if FIX_CU_BASED_MRG_CAND_LIST_B0136 4371 else 4372 { 4373 pcMvFieldNeighbours[ iCount<<1 ].setMvField( TComMv(0,0), NOT_VALID ); 4374 } 4375 #endif 4376 if( ( iPdmInterDir & 2 ) == 2 ) 4377 { 4378 pcMvFieldNeighbours[(iCount<<1)+1 ].setMvField( acPdmMv[ 1 ], aiPdmRefIdx[ 1 ] ); 4379 } 4380 #if FIX_CU_BASED_MRG_CAND_LIST_B0136 4381 else 4382 { 4383 pcMvFieldNeighbours[(iCount<<1)+1 ].setMvField( TComMv(0,0), NOT_VALID ); 4384 } 4385 #endif 4386 #if SIMP_MRG_PRUN 4387 if ( mrgCandIdx == iCount ) 4388 { 4389 return; 4390 } 4391 #endif 4392 iCount ++; 4393 } 4394 #endif 4357 #endif // HHI_INTER_VIEW_MOTION_PRED 4395 4358 4396 4359 #if MERL_VSP_COMPENSATION_C0152 … … 4459 4422 } 4460 4423 4461 #if HHI_INTER_VIEW_MOTION_PRED 4462 #if QC_MRG_CANS_B0048 4424 #if H3D_IVMP 4463 4425 if( iPdmDir[0] && !bNoPdmMerge && PDM_MERGE_POS == 3 ) 4464 #else4465 if( iPdmInterDir && !bNoPdmMerge && PDM_MERGE_POS == 3 )4466 #endif4467 4426 { 4468 4427 abCandIsInter [ iCount ] = true; … … 4496 4455 iCount ++; 4497 4456 } 4498 #endif 4499 4500 #if OL_DISMV_POS_B0069 4457 4501 4458 if(extraMergeCand) 4502 4459 { … … 4546 4503 } 4547 4504 } 4548 #endif 4505 #endif //HHI_INTER_VIEW_MOTION_PRED 4506 4549 4507 #if MERL_VSP_COMPENSATION_C0152 4550 4508 //===== vsp 3 ===== … … 4556 4514 #if MERL_VSP_C0152 4557 4515 #if VSP_MERGE_POS < 4 4558 #if H HI_INTER_VIEW_MOTION_PRED4516 #if H3D_IVMP 4559 4517 if( iCount < 4 + extraMergeCand ) 4560 4518 #else … … 4628 4586 #endif 4629 4587 4630 #if HHI_INTER_VIEW_MOTION_PRED 4631 #if QC_MRG_CANS_B0048 4588 #if H3D_IVMP 4632 4589 if( iPdmDir[0] && !bNoPdmMerge && PDM_MERGE_POS == 4 ) 4633 #else4634 if( iPdmInterDir && !bNoPdmMerge && PDM_MERGE_POS == 4 )4635 #endif4636 4590 { 4637 4591 abCandIsInter [ iCount ] = true; … … 4665 4619 iCount ++; 4666 4620 } 4667 #endif 4621 #endif // HHI_INTER_VIEW_MOTION_PRED 4668 4622 4669 4623 #if MERL_VSP_COMPENSATION_C0152 … … 4675 4629 4676 4630 // above left 4677 #if H HI_INTER_VIEW_MOTION_PRED4631 #if H3D_IVMP 4678 4632 if( iCount < 4 + extraMergeCand ) 4679 4633 #else … … 4749 4703 4750 4704 if ( getSlice()->getPPS()->getEnableTMVPFlag() 4751 #if QC_MRG_CANS_B00484705 #if H3D_IVMP 4752 4706 && iCount < (MRG_MAX_NUM_CANDS_SIGNALED + extraMergeCand) 4753 4707 #endif … … 4919 4873 UInt uiArrayAddr = iCount; 4920 4874 #else 4921 #if H HI_INTER_VIEW_MOTION_PRED4875 #if H3D_IVMP 4922 4876 for( UInt uiOuter = 0; uiOuter < MRG_MAX_NUM_CANDS_MEM; uiOuter++ ) 4923 4877 #else … … 4927 4881 if( abCandIsInter[ uiOuter ] ) 4928 4882 { 4929 #if H HI_INTER_VIEW_MOTION_PRED4883 #if H3D_IVMP 4930 4884 for( UInt uiIter = uiOuter + 1; uiIter < MRG_MAX_NUM_CANDS_MEM; uiIter++ ) 4931 4885 #else … … 4978 4932 } 4979 4933 4980 #if H HI_INTER_VIEW_MOTION_PRED4934 #if H3D_IVMP 4981 4935 bool abCandIsInterFlag[MRG_MAX_NUM_CANDS_MEM]; 4982 4936 for (int i=0; i<MRG_MAX_NUM_CANDS_MEM; i++) … … 4992 4946 UInt uiArrayAddr = 0; 4993 4947 4994 #if H HI_INTER_VIEW_MOTION_PRED4948 #if H3D_IVMP 4995 4949 for (int i=0; i<MRG_MAX_NUM_CANDS_MEM; i++) 4996 4950 #else … … 5008 4962 } 5009 4963 5010 #if H HI_INTER_VIEW_MOTION_PRED4964 #if H3D_IVMP 5011 4965 for (int i=uiArrayAddr; i<MRG_MAX_NUM_CANDS_MEM; i++) 5012 4966 #else … … 5029 4983 if ( getSlice()->isInterB() ) 5030 4984 { 5031 #if H HI_INTER_VIEW_MOTION_PRED4985 #if H3D_IVMP 5032 4986 Int iCombinedCount = 0; 5033 4987 Int iMaxCombCount = ( extraMergeCand ? 6 : 5 ); … … 5081 5035 #if !REMOVE_NON_SCALED 5082 5036 Int iScaledCount = 0; 5083 #if H HI_INTER_VIEW_MOTION_PRED5037 #if H3D_IVMP 5084 5038 for (int i=0; i<uiCutoff && uiArrayAddr!=MRG_MAX_NUM_CANDS_MEM && iScaledCount<1; i++) 5085 5039 #else … … 5087 5041 #endif 5088 5042 { 5089 #if H HI_INTER_VIEW_MOTION_PRED5043 #if H3D_IVMP 5090 5044 for (int j=0; j<2 && uiArrayAddr!=MRG_MAX_NUM_CANDS_MEM && iScaledCount<1; j++) 5091 5045 #else … … 5130 5084 5131 5085 Int iNumRefIdx = (getSlice()->isInterB()) ? min(m_pcSlice->getNumRefIdx(REF_PIC_LIST_0), m_pcSlice->getNumRefIdx(REF_PIC_LIST_1)) : m_pcSlice->getNumRefIdx(REF_PIC_LIST_0); 5132 #if H HI_INTER_VIEW_MOTION_PRED5086 #if H3D_IVMP 5133 5087 for (int r=0; r<iNumRefIdx && uiArrayAddr!=MRG_MAX_NUM_CANDS_MEM; r++) 5134 5088 #else … … 5153 5107 uiArrayAddr++; 5154 5108 } 5155 #if H HI_INTER_VIEW_MOTION_PRED5109 #if H3D_IVMP 5156 5110 if (uiArrayAddr > MRG_MAX_NUM_CANDS_SIGNALED + extraMergeCand ) 5157 5111 { … … 6677 6631 * \param pInfo 6678 6632 */ 6679 #if SHARP_INTERVIEW_DECOUPLE_B01116633 #if H3D_IVMP 6680 6634 Void TComDataCU::fillMvpCand ( UInt uiPartIdx, UInt uiPartAddr, RefPicList eRefPicList, Int iRefIdx, AMVPInfo* pInfo, Int iMVPIdx) 6681 6635 { … … 6721 6675 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 6722 6676 Int paiPdmRefIdx[4] = {-1, -1, -1, -1}; 6723 Int iPdmDir[4] = {-1, -1, -1, -1};6677 Int iPdmDir[4] = {-1, -1, -1, -1}; 6724 6678 #if QC_C0051_FIXED_BY_MTK 6725 6679 TComMv cPdmMvPred[4]; … … 6762 6716 6763 6717 Void TComDataCU::fillMvpCandBase( UInt uiPartIdx, UInt uiPartAddr, RefPicList eRefPicList, Int iRefIdx, AMVPInfo* pInfo ) 6764 #else 6718 #else // HHI_INTER_VIEW_MOTION_PRED 6765 6719 Void TComDataCU::fillMvpCand ( UInt uiPartIdx, UInt uiPartAddr, RefPicList eRefPicList, Int iRefIdx, AMVPInfo* pInfo ) 6766 #endif 6720 #endif // HHI_INTER_VIEW_MOTION_PRED 6767 6721 { 6768 6722 PartSize eCUMode = getPartitionSize( 0 ); … … 6776 6730 return; 6777 6731 } 6778 6779 #if H3D_NBDV && !SHARP_INTERVIEW_DECOUPLE_B01116780 DisInfo cDisInfo;6781 cDisInfo.iN = 0;6782 if(m_pcSlice->getSPS()->getViewId() && m_pcSlice->getSPS()->getMultiviewMvPredMode())6783 {6784 getDisMvpCandNBDV(uiPartIdx, uiPartAddr, &cDisInfo, false);6785 }6786 if(cDisInfo.iN==0)6787 {6788 cDisInfo.iN = 1;6789 cDisInfo.m_acMvCand[0].setHor(0);6790 cDisInfo.m_acMvCand[0].setVer(0);6791 cDisInfo.m_aVIdxCan[0] = 0;6792 }6793 #endif6794 #if HHI_INTER_VIEW_MOTION_PRED && !SHARP_INTERVIEW_DECOUPLE_B01116795 #if ( PDM_AMVP_POS == 0 )6796 // get inter-view mv predictor (at position 0)6797 TComMv cPdmMvPred;6798 #if H3D_NBDV6799 if( getPdmMvPredDisCan( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred, &cDisInfo ) )6800 #else6801 if( getPdmMvPred( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred ) )6802 #endif6803 {6804 clipMv( cPdmMvPred );6805 pInfo->m_acMvCand[ pInfo->iN++ ] = cPdmMvPred;6806 }6807 #endif6808 #endif6809 6732 6810 6733 //-- Get Spatial MV … … 6851 6774 } 6852 6775 6853 #if HHI_INTER_VIEW_MOTION_PRED && !SHARP_INTERVIEW_DECOUPLE_B01116854 #if ( PDM_AMVP_POS == 1 )6855 // get inter-view mv predictor (at position 1)6856 TComMv cPdmMvPred;6857 #if H3D_NBDV6858 if( getPdmMvPredDisCan( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred, &cDisInfo ) )6859 #else6860 if( getPdmMvPred( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred ) )6861 #endif6862 {6863 clipMv( cPdmMvPred );6864 pInfo->m_acMvCand[ pInfo->iN++ ] = cPdmMvPred;6865 }6866 #endif6867 #endif6868 6869 6776 // Above predictor search 6870 6777 bAdded = xAddMVPCand( pInfo, eRefPicList, iRefIdx, uiPartIdxRT, MD_ABOVE_RIGHT); … … 6903 6810 } 6904 6811 6905 #if HHI_INTER_VIEW_MOTION_PRED && !SHARP_INTERVIEW_DECOUPLE_B01116906 #if ( PDM_AMVP_POS == 2 )6907 // get inter-view mv predictor (at position 2)6908 TComMv cPdmMvPred;6909 #if H3D_NBDV6910 if( getPdmMvPredDisCan( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred, &cDisInfo ) )6911 #else6912 if( getPdmMvPred( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred ) )6913 #endif6914 {6915 clipMv( cPdmMvPred );6916 pInfo->m_acMvCand[ pInfo->iN++ ] = cPdmMvPred;6917 }6918 #endif6919 #endif6920 6812 6921 6813 #if AMVP_PRUNING_SIMPLIFICATION … … 6930 6822 } 6931 6823 } 6932 #if H3D_NBDV && !SHARP_INTERVIEW_DECOUPLE_B01116933 if ( getSlice()->getViewId()!=0 && pInfo->iN == 3 )6934 {6935 if ( pInfo->m_acMvCand[ 1 ] == pInfo->m_acMvCand[ 2 ] )6936 {6937 pInfo->iN = 2;6938 if( pInfo->m_acMvCand[ 0 ] == pInfo->m_acMvCand[ 1 ] )6939 pInfo->iN = 1;6940 }6941 else6942 {6943 if( pInfo->m_acMvCand[ 0 ] == pInfo->m_acMvCand[ 1 ] )6944 {6945 pInfo->m_acMvCand[1 ] = pInfo->m_acMvCand[ 2 ];6946 pInfo->iN = 2;6947 }6948 else if (pInfo->m_acMvCand[ 0 ] == pInfo->m_acMvCand[ 2 ])6949 {6950 pInfo->iN = 2;6951 }6952 }6953 }6954 #endif6955 6824 #endif 6956 6825 … … 7025 6894 } 7026 6895 7027 #if HHI_INTER_VIEW_MOTION_PRED && !SHARP_INTERVIEW_DECOUPLE_B01117028 #if ( PDM_AMVP_POS == 3 )7029 // get inter-view mv predictor (at position 3)7030 TComMv cPdmMvPred;7031 #if H3D_NBDV7032 if( getPdmMvPredDisCan( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred, &cDisInfo ) )7033 #else7034 if( getPdmMvPred( uiPartIdx, eRefPicList, iRefIdx, cPdmMvPred ) )7035 #endif7036 {7037 clipMv( cPdmMvPred );7038 pInfo->m_acMvCand[ pInfo->iN++ ] = cPdmMvPred;7039 }7040 #endif7041 #endif7042 7043 6896 #if !AMVP_PRUNING_SIMPLIFICATION 7044 6897 // Check No MV Candidate … … 7046 6899 #endif 7047 6900 7048 #if HHI_INTER_VIEW_MOTION_PRED && !SHARP_INTERVIEW_DECOUPLE_B01117049 const Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 );7050 if (pInfo->iN > iNumAMVPCands)7051 {7052 pInfo->iN = iNumAMVPCands;7053 }7054 else if (pInfo->iN < iNumAMVPCands)7055 #else7056 6901 if (pInfo->iN > AMVP_MAX_NUM_CANDS) 7057 6902 { … … 7059 6904 } 7060 6905 else if (pInfo->iN < AMVP_MAX_NUM_CANDS) 7061 #endif7062 6906 { 7063 6907 #if !AMVP_ZERO_CHECKING_REMOVAL … … 8726 8570 // public functions for Multi-view tools 8727 8571 // ------------------------------------------------------------------------------------------------------------------- 8728 #if H HI_INTER_VIEW_MOTION_PRED8572 #if H3D_IVMP 8729 8573 #if !H3D_NBDV 8730 8574 Int … … 8757 8601 #else 8758 8602 Int 8759 TComDataCU::getPdmMergeCandidateDisCan( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo 8760 #if QC_MRG_CANS_B0048 8761 , Int* iPdm 8762 #endif 8763 ) 8603 TComDataCU::getPdmMergeCandidateDisCan( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm ) 8764 8604 { 8765 8605 TComDepthMapGenerator* pcDepthMapGenerator = m_pcSlice->getSPS()->getDepthMapGenerator(); 8766 8606 ROFRS( pcDepthMapGenerator, 0 ); 8767 return pcDepthMapGenerator->getPdmMergeCandidate( this, uiPartIdx, paiPdmRefIdx, pacPdmMv, pDInfo 8768 #if QC_MRG_CANS_B0048 8769 , iPdm 8770 #endif 8771 ); 8607 return pcDepthMapGenerator->getPdmMergeCandidate( this, uiPartIdx, paiPdmRefIdx, pacPdmMv, pDInfo, iPdm ); 8772 8608 } 8773 8609 Bool -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDataCU.h
r290 r292 563 563 ,Bool bIndependentTileBoundaryEnabled ); 564 564 565 #if H HI_INTER_VIEW_MOTION_PRED565 #if H3D_IVMP 566 566 #if !H3D_NBDV 567 Int getPdmMergeCandidate ( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv );568 Bool getPdmMvPred ( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, Bool bMerge = false );567 Int getPdmMergeCandidate ( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv ); 568 Bool getPdmMvPred ( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, Bool bMerge = false ); 569 569 #else //!H3D_NBDV 570 570 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 571 Bool getUnifiedMvPredCan(UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm, Bool bMerge );571 Bool getUnifiedMvPredCan ( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm, Bool bMerge ); 572 572 #else //QC_AMVP_MRG_UNIFY_IVCAN_C0051 573 Bool getPdmMvPredDisCan( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, DisInfo* pDInfo, Bool bMerge = false ); 574 Int getPdmMergeCandidateDisCan( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo 575 #if QC_MRG_CANS_B0048 576 , Int* iPdm 577 #endif //QC_MRG_CANS_B0048 578 ); 573 Bool getPdmMvPredDisCan ( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, DisInfo* pDInfo, Bool bMerge = false ); 574 Int getPdmMergeCandidateDisCan( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm ); 579 575 #endif //QC_AMVP_MRG_UNIFY_IVCAN_C0051 580 576 Void getDisMvpCand ( UInt uiPartIdx, UInt uiPartAddr, DisInfo* pDInfo ); … … 598 594 #endif 599 595 Bool getIViewOrgDepthMvPred( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv ); 600 #endif 596 #endif // HHI_INTER_VIEW_MOTION_PRED 601 597 #if HHI_INTER_VIEW_RESIDUAL_PRED 602 598 Bool* getResPredAvail () { return m_pbResPredAvailable; } … … 637 633 638 634 AMVP_MODE getAMVPMode ( UInt uiIdx ); 639 #if SHARP_INTERVIEW_DECOUPLE_B0111635 #if H3D_IVMP 640 636 Void fillMvpCandBase ( UInt uiPartIdx, UInt uiPartAddr, RefPicList eRefPicList, Int iRefIdx, AMVPInfo* pInfo ); 641 637 Void fillMvpCand ( UInt uiPartIdx, UInt uiPartAddr, RefPicList eRefPicList, Int iRefIdx, AMVPInfo* pInfo , Int iMVPIdx=-1); 642 #else643 Void fillMvpCand ( UInt uiPartIdx, UInt uiPartAddr, RefPicList eRefPicList, Int iRefIdx, AMVPInfo* pInfo );644 638 #endif 645 639 #if PARALLEL_MERGE -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDepthMapGenerator.cpp
r289 r292 46 46 #if DEPTH_MAP_GENERATION 47 47 48 49 48 TComDepthMapGenerator::TComDepthMapGenerator() 50 49 { … … 565 564 #endif //!H3D_NBDV 566 565 567 #if H HI_INTER_VIEW_MOTION_PRED566 #if H3D_IVMP 568 567 Void 569 568 TComDepthMapGenerator::covertOrgDepthMap( TComPic* pcPic ) … … 605 604 606 605 607 #if H HI_INTER_VIEW_MOTION_PRED606 #if H3D_IVMP 608 607 #if QC_AMVP_MRG_UNIFY_IVCAN_C0051 609 608 Bool … … 630 629 ROTRS( !bPdmMerge, 0 ); 631 630 632 #if QC_MRG_CANS_B0048 631 633 632 Bool abPdmAvailable[4] = {false, false, false, false}; 634 #else635 Bool abPdmAvailable[2] = {false,false};636 #endif637 633 638 634 Int iValid = 0; … … 765 761 if( pcSlice->getRefPOC( eRefPicListDMV, iPdmRefIdx ) == pcSlice->getPOC()) 766 762 { 767 #if QC_MRG_CANS_B0048768 763 abPdmAvailable[ iRefListId+2 ] = true; 769 764 paiPdmRefIdx [ iRefListId+2 ] = iPdmRefIdx; 770 #else771 abPdmAvailable[ iRefListId ] = true;772 paiPdmRefIdx [ iRefListId ] = iPdmRefIdx;773 #endif774 765 #if H3D_NBDV 775 766 TComMv cMv = pDInfo->m_acMvCand[0]; … … 779 770 #endif 780 771 pcCU->clipMv( cMv ); 781 #if QC_MRG_CANS_B0048782 772 pacPdmMv [ iRefListId + 2] = cMv; 783 #else784 pacPdmMv [ iRefListId ] = cMv;785 #endif786 773 if(bMerge) 787 774 break; … … 794 781 } 795 782 } 796 #if QC_MRG_CANS_B0048797 783 iPdm[1] = ( abPdmAvailable[2] ? 1 : 0 ) + ( abPdmAvailable[3] ? 2 : 0 ); 798 #else799 iPdmInterDir = ( abPdmAvailable[0] ? 1 : 0 ) + ( abPdmAvailable[1] ? 2 : 0 ) ;800 }801 #endif802 784 } 803 785 return false; 804 786 } 805 #else 787 #else // QC_AMVP_MRG_UNIFY_IVCAN_C0051 806 788 #if H3D_NBDV 807 789 Int 808 TComDepthMapGenerator::getPdmMergeCandidate( TComDataCU* pcCU, UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo 809 #if QC_MRG_CANS_B0048 810 , Int* iPdm 811 #endif 812 ) 790 TComDepthMapGenerator::getPdmMergeCandidate( TComDataCU* pcCU, UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm ) 813 791 #else 814 792 Int … … 816 794 #endif 817 795 { 818 #if MTK_INTERVIEW_MERGE_A0049819 796 AOF ( m_bCreated && m_bInit ); 820 797 … … 829 806 ROTRS( !bPdmMerge, 0 ); 830 807 831 #if QC_MRG_CANS_B0048832 808 Bool abPdmAvailable[4] = {false, false, false, false}; 833 #else834 Bool abPdmAvailable[2] = {false,false};835 #endif836 809 837 810 Int iValid = 0; … … 935 908 } 936 909 Int iPdmInterDir = ( abPdmAvailable[0] ? 1 : 0 ) + ( abPdmAvailable[1] ? 2 : 0 ); 937 #if QC_MRG_CANS_B0048 910 938 911 iPdm[0] = iPdmInterDir; 939 #else940 if (iPdmInterDir == 0)941 {942 #endif943 912 for( Int iRefListId = 0; iRefListId < 2 ; iRefListId++ ) 944 913 { … … 949 918 if( pcSlice->getRefPOC( eRefPicList, iPdmRefIdx ) == pcSlice->getPOC()) 950 919 { 951 #if QC_MRG_CANS_B0048952 920 abPdmAvailable[ iRefListId+2 ] = true; 953 921 paiPdmRefIdx [ iRefListId+2 ] = iPdmRefIdx; 954 #else955 abPdmAvailable[ iRefListId ] = true;956 paiPdmRefIdx [ iRefListId ] = iPdmRefIdx;957 #endif958 922 #if H3D_NBDV 959 923 TComMv cMv = pDInfo->m_acMvCand[0]; … … 963 927 #endif 964 928 pcCU->clipMv( cMv ); 965 #if QC_MRG_CANS_B0048966 929 pacPdmMv [ iRefListId + 2] = cMv; 967 #else968 pacPdmMv [ iRefListId ] = cMv;969 #endif970 930 break; 971 931 } 972 932 } 973 933 } 974 #if QC_MRG_CANS_B0048975 934 iPdmInterDir = ( abPdmAvailable[2] ? 1 : 0 ) + ( abPdmAvailable[3] ? 2 : 0 ) ; 976 935 iPdm[1] = iPdmInterDir; 977 #else978 iPdmInterDir = ( abPdmAvailable[0] ? 1 : 0 ) + ( abPdmAvailable[1] ? 2 : 0 ) ;979 }980 #endif981 936 982 937 return iPdmInterDir; 983 984 #else985 Int iMaxNumInterPics = 1;986 Int iMaxNumAllPics = 2;987 988 // inter-only989 Bool abPdmAvailable[2] = {false,false};990 for( Int iRefListId = 0; iRefListId < 2; iRefListId++ )991 {992 RefPicList eRefPicList = RefPicList( iRefListId );993 Int iNumRefPics = pcCU->getSlice()->getNumRefIdx( eRefPicList );994 TComMv cMv;995 for( Int iPdmRefIdx = 0, iInterPics = 0; iPdmRefIdx < iNumRefPics && iInterPics < iMaxNumInterPics; iPdmRefIdx++ )996 {997 if( pcCU->getSlice()->getRefPOC( eRefPicList, iPdmRefIdx ) != pcCU->getSlice()->getPOC() )998 {999 #if H3D_NBDV1000 if( getDisCanPdmMvPred (pcCU, uiPartIdx, eRefPicList, iPdmRefIdx, cMv, pDInfo, true ) )1001 #else1002 if( getPdmMvPred( pcCU, uiPartIdx, eRefPicList, iPdmRefIdx, cMv, true ) )1003 #endif1004 {1005 pcCU->clipMv( cMv );1006 abPdmAvailable[ iRefListId ] = true;1007 paiPdmRefIdx [ iRefListId ] = iPdmRefIdx;1008 pacPdmMv [ iRefListId ] = cMv;1009 break;1010 }1011 iInterPics++;1012 }1013 }1014 }1015 Int iPdmInterDir = ( abPdmAvailable[0] ? 1 : 0 ) + ( abPdmAvailable[1] ? 2 : 0 );1016 if( 0==iPdmInterDir )1017 { // check all, including inter view references1018 for( Int iRefListId = 0; iRefListId < 2; iRefListId++ )1019 {1020 RefPicList eRefPicList = RefPicList( iRefListId );1021 Int iNumRefPics = Min( iMaxNumAllPics, pcCU->getSlice()->getNumRefIdx( eRefPicList ) );1022 TComMv cMv;1023 for( Int iPdmRefIdx = 0; iPdmRefIdx < iNumRefPics; iPdmRefIdx++ )1024 {1025 #if H3D_NBDV1026 if ( getDisCanPdmMvPred (pcCU, uiPartIdx, eRefPicList, iPdmRefIdx, cMv, pDInfo, true ) )1027 #else1028 if( getPdmMvPred( pcCU, uiPartIdx, eRefPicList, iPdmRefIdx, cMv, true ) )1029 #endif1030 {1031 pcCU->clipMv( cMv );1032 abPdmAvailable[ iRefListId ] = true;1033 paiPdmRefIdx [ iRefListId ] = iPdmRefIdx;1034 pacPdmMv [ iRefListId ] = cMv;1035 break;1036 }1037 }1038 }1039 iPdmInterDir = ( abPdmAvailable[0] ? 1 : 0 ) + ( abPdmAvailable[1] ? 2 : 0 );1040 }1041 return iPdmInterDir;1042 #endif1043 938 } 1044 939 … … 1215 1110 } 1216 1111 #endif // H3D_NBDV 1217 #endif 1112 #endif // QC_AMVP_MRG_UNIFY_IVCAN_C0051 1218 1113 1219 1114 … … 1257 1152 return true; 1258 1153 } 1259 #endif 1154 #endif // HHI_INTER_VIEW_MOTION_PRED 1260 1155 1261 1156 … … 2057 1952 Int iCurrPosY; 2058 1953 pcPredDepthMap->getTopLeftSamplePos( pcCU->getAddr(), pcCU->getZorderIdxInCU() + uiPartAddr, iCurrPosX, iCurrPosY ); 2059 #if SAIT_IMPROV_MOTION_PRED_M24829// max disparity within PU1954 #if H3D_IVMP // max disparity within PU 2060 1955 Int DiWidth = iCurrPosX+(iWidth >> m_uiSubSampExpX); 2061 1956 Int DiHeight = iCurrPosY+(iHeight >> m_uiSubSampExpY); -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDepthMapGenerator.h
r289 r292 142 142 #endif 143 143 144 #if H HI_INTER_VIEW_MOTION_PRED144 #if H3D_IVMP 145 145 Void covertOrgDepthMap ( TComPic* pcPic ); 146 146 #endif … … 150 150 UInt getSubSampExpY () { return m_uiSubSampExpY; } 151 151 Int getDisparity ( TComPic* pcPic, Int iPosX, Int iPosY, UInt uiRefViewId ); 152 #if H HI_INTER_VIEW_MOTION_PRED152 #if H3D_IVMP 153 153 #if H3D_NBDV 154 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 );155 Bool getPdmCandidate ( TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm, Bool bMerge ); 156 156 #else 157 Int getPdmMergeCandidate ( TComDataCU* pcCU, UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo 158 #if QC_MRG_CANS_B0048 159 , Int* iPdm 160 #endif 161 ); 162 157 Int getPdmMergeCandidate ( TComDataCU* pcCU, UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv, DisInfo* pDInfo, Int* iPdm ); 163 158 Bool getPdmMvPredDisCan ( TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, DisInfo* pDInfo, Bool bMerge ); 164 159 Bool getDisCanPdmMvPred ( TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, DisInfo* pDInfo, Bool bMerge ); -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComMotionInfo.h
r289 r292 94 94 Int getHor () const { return m_acMv.getHor(); } 95 95 Int getVer () const { return m_acMv.getVer(); } 96 #if QC_MRG_CANS_B004896 #if H3D_IVMP 97 97 Bool operator== ( const TComMvField& rcMv ) const 98 98 { -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComPic.cpp
r289 r292 59 59 #endif 60 60 #endif 61 #if H HI_INTER_VIEW_MOTION_PRED61 #if H3D_IVMP 62 62 m_pcOrgDepthMap = NULL; 63 63 #endif … … 157 157 #endif 158 158 #endif 159 #if H HI_INTER_VIEW_MOTION_PRED159 #if H3D_IVMP 160 160 if( m_pcOrgDepthMap ) 161 161 { … … 206 206 #endif 207 207 208 #if H HI_INTER_VIEW_MOTION_PRED208 #if H3D_IVMP 209 209 Void 210 210 TComPic::addOrgDepthMapBuffer() … … 259 259 #endif 260 260 261 #if H HI_INTER_VIEW_MOTION_PRED261 #if H3D_IVMP 262 262 Void 263 263 TComPic::removeOrgDepthMapBuffer() -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComPic.h
r289 r292 77 77 #endif 78 78 79 #if H HI_INTER_VIEW_MOTION_PRED79 #if H3D_IVMP 80 80 TComPicYuv* m_pcOrgDepthMap; // original depth map 81 81 #if H3D_NBDV … … 165 165 166 166 #endif 167 #if H HI_INTER_VIEW_MOTION_PRED167 #if H3D_IVMP 168 168 TComPicYuv* getOrgDepthMap() { return m_pcOrgDepthMap; } 169 169 #if H3D_NBDV … … 250 250 Void addPrdDepthMapBuffer ( UInt uiSubSampExpX, UInt uiSubSampExpY ); 251 251 #endif 252 #if H HI_INTER_VIEW_MOTION_PRED252 #if H3D_IVMP 253 253 Void addOrgDepthMapBuffer (); 254 254 #endif … … 259 259 Void removePrdDepthMapBuffer (); 260 260 #endif 261 #if H HI_INTER_VIEW_MOTION_PRED261 #if H3D_IVMP 262 262 Void removeOrgDepthMapBuffer (); 263 263 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComRdCost.cpp
r189 r292 181 181 } 182 182 183 #if H HI_INTER_VIEW_MOTION_PRED183 #if H3D_IVMP 184 184 Void 185 185 TComRdCost::setLambdaMVReg( Double dLambda ) -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComRdCost.h
r189 r292 203 203 #endif 204 204 Void setLambda ( Double dLambda ); 205 #if H HI_INTER_VIEW_MOTION_PRED205 #if H3D_IVMP 206 206 Void setLambdaMVReg ( Double dLambda ); 207 207 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComSlice.cpp
r287 r292 1656 1656 ::memset( m_aiPdmOffset, 0x00, sizeof( m_aiPdmOffset ) ); 1657 1657 #endif 1658 #if H HI_INTER_VIEW_MOTION_PRED1658 #if H3D_IVMP 1659 1659 m_uiMultiviewMvPredMode = 0; 1660 1660 #endif … … 1890 1890 1891 1891 m_uiPredDepthMapGeneration = uiPdmGenMode; 1892 #if H HI_INTER_VIEW_MOTION_PRED1892 #if H3D_IVMP 1893 1893 m_uiMultiviewMvPredMode = uiPdmMvPredMode; 1894 1894 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComSlice.h
r280 r292 415 415 #endif 416 416 417 #if H HI_INTER_VIEW_MOTION_PRED417 #if H3D_IVMP 418 418 UInt m_uiMultiviewMvPredMode; 419 419 #endif … … 722 722 #endif 723 723 724 #if H HI_INTER_VIEW_MOTION_PRED724 #if H3D_IVMP 725 725 UInt getMultiviewMvPredMode () { return m_uiMultiviewMvPredMode; } 726 726 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TypeDef.h
r291 r292 79 79 #define INTER_VIEW_VECTOR_SCALING_C0116 1 // JCT3V-C0116 Inter-view vector scaling for AMVP 80 80 81 ///// ***** INTERVIEW MOTION VECTOR PREDICTION ********* 82 #define HHI_INTER_VIEW_MOTION_PRED 1 // inter-view motion parameter prediction 83 #if HHI_INTER_VIEW_MOTION_PRED 84 #define SAIT_IMPROV_MOTION_PRED_M24829 1 // improved inter-view motion vector prediction 85 #else 86 #define SAIT_IMPROV_MOTION_PRED_M24829 0 87 #endif 88 89 #define SHARP_INTERVIEW_DECOUPLE_B0111 1 // JCT3V-B0111 decoupling inter-view candidate 90 #define QC_MRG_CANS_B0048 1 // JCT3V-B0048, B0086, B0069 91 #if QC_MRG_CANS_B0048 92 #define OL_DISMV_POS_B0069 1 // different pos for disparity MV candidate, B0069 93 #endif 94 #define MTK_INTERVIEW_MERGE_A0049 1 // JCT3V-A0049 second part 81 ///// ***** INTERVIEW MOTION PARAMETER PREDICTION ********* 82 #define H3D_IVMP 1 // inter-view motion parameter prediction 83 // HHI_INTER_VIEW_MOTION_PRED 84 // SAIT_IMPROV_MOTION_PRED_M24829, improved inter-view motion vector prediction 85 // SHARP_INTERVIEW_DECOUPLE_B0111, decoupling inter-view candidate 86 // QC_MRG_CANS_B0048 , JCT3V-B0048, B0086, B0069 87 // OL_DISMV_POS_B0069 , different pos for disparity MV candidate, B0069 88 // MTK_INTERVIEW_MERGE_A0049 ,// JCT3V-A0049 second part 95 89 #define QC_AMVP_MRG_UNIFY_IVCAN_C0051 1 96 90 #define QC_C0051_FIXED_BY_MTK 1 // bug fix for C0051 implementation -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecCAVLC.cpp
r287 r292 1844 1844 #if DEPTH_MAP_GENERATION 1845 1845 UInt uiPredDepthMapGeneration = 0, uiPdmPrecision = 0; 1846 #if H HI_INTER_VIEW_MOTION_PRED1846 #if H3D_IVMP 1847 1847 UInt uiMultiviewMvPredMode = 0; 1848 1848 #endif … … 1859 1859 READ_SVLC( iCode, "Pdm_offset" ); m_aaiTempPdmOffset [ uiViewId ][ uiBaseId ] = iCode; 1860 1860 } 1861 #if H HI_INTER_VIEW_MOTION_PRED1861 #if H3D_IVMP 1862 1862 READ_UVLC( uiMultiviewMvPredMode, "multi_view_mv_pred_mode" ); 1863 1863 #endif … … 1866 1866 #endif 1867 1867 } 1868 #if H HI_INTER_VIEW_MOTION_PRED1868 #if H3D_IVMP 1869 1869 pcSPS->setPredDepthMapGeneration( uiViewId, false, uiPredDepthMapGeneration, uiMultiviewMvPredMode, uiPdmPrecision, m_aaiTempPdmScaleNomDelta, m_aaiTempPdmOffset ); 1870 1870 #else … … 2501 2501 } 2502 2502 2503 #if ( HHI_MPI || H HI_INTER_VIEW_MOTION_PRED)2504 #if ( HHI_MPI && H HI_INTER_VIEW_MOTION_PRED)2503 #if ( HHI_MPI || H3D_IVMP ) 2504 #if ( HHI_MPI && H3D_IVMP ) 2505 2505 const int iExtraMergeCandidates = ( sps->getUseMVI() || sps->getMultiviewMvPredMode() ) ? 1 : 0; 2506 2506 #elif HHI_MPI … … 2780 2780 #endif 2781 2781 2782 #if H HI_INTER_VIEW_MOTION_PRED2782 #if H3D_IVMP 2783 2783 Void TDecCavlc::parseMVPIdx( Int& riMVPIdx, Int iAMVPCands ) 2784 2784 #else -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecCAVLC.h
r280 r292 141 141 Void parseTerminatingBit ( UInt& ruiBit ); 142 142 143 #if H HI_INTER_VIEW_MOTION_PRED143 #if H3D_IVMP 144 144 Void parseMVPIdx ( Int& riMVPIdx, Int iAMVPCands ); 145 145 #else -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecCu.cpp
r287 r292 339 339 m_ppcCU[uiDepth]->copyInterPredInfoFrom( pcCU, uiAbsPartIdx, REF_PIC_LIST_0 ); 340 340 m_ppcCU[uiDepth]->copyInterPredInfoFrom( pcCU, uiAbsPartIdx, REF_PIC_LIST_1 ); 341 #if H HI_INTER_VIEW_MOTION_PRED341 #if H3D_IVMP 342 342 TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS_MEM << 1]; // double length for mv of both lists 343 343 UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS_MEM]; -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecEntropy.cpp
r290 r292 276 276 277 277 #if CU_BASED_MRG_CAND_LIST 278 #if H HI_INTER_VIEW_MOTION_PRED278 #if H3D_IVMP 279 279 TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS_MEM << 1]; // double length for mv of both lists 280 280 UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS_MEM]; … … 297 297 { 298 298 #if !CU_BASED_MRG_CAND_LIST 299 #if H HI_INTER_VIEW_MOTION_PRED299 #if H3D_IVMP 300 300 TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS_MEM << 1]; // double length for mv of both lists 301 301 UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS_MEM]; … … 523 523 if ( (pcSubCU->getInterDir(uiPartAddr) & ( 1 << eRefList )) && (pcSubCU->getAMVPMode(uiPartAddr) == AM_EXPL) ) 524 524 { 525 #if H HI_INTER_VIEW_MOTION_PRED525 #if H3D_IVMP 526 526 const Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcSubCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 527 527 m_pcEntropyDecoderIf->parseMVPIdx( iMVPIdx, iNumAMVPCands ); … … 530 530 #endif 531 531 } 532 #if SHARP_INTERVIEW_DECOUPLE_B0111532 #if H3D_IVMP 533 533 pcSubCU->fillMvpCand(uiPartIdx, uiPartAddr, eRefList, iRefIdx, pAMVPInfo, iMVPIdx); 534 534 #else -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecEntropy.h
r280 r292 99 99 virtual Void parseTerminatingBit ( UInt& ruilsLast ) = 0; 100 100 101 #if H HI_INTER_VIEW_MOTION_PRED101 #if H3D_IVMP 102 102 virtual Void parseMVPIdx ( Int& riMVPIdx, Int iNumAMVPCands ) = 0; 103 103 #else -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecSbac.cpp
r287 r292 728 728 #endif 729 729 730 #if H HI_INTER_VIEW_MOTION_PRED730 #if H3D_IVMP 731 731 Void TDecSbac::parseMVPIdx ( Int& riMVPIdx, Int iNumAMVPCands ) 732 732 { -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecSbac.h
r287 r292 114 114 115 115 Void parseTerminatingBit ( UInt& ruiBit ); 116 #if H HI_INTER_VIEW_MOTION_PRED116 #if H3D_IVMP 117 117 Void parseMVPIdx ( Int& riMVPIdx, Int iNumAMVPCands ); 118 118 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCavlc.cpp
r287 r292 795 795 WRITE_SVLC( pcSPS->getPdmOffset ()[ uiId ], "Pdm_offset" ); 796 796 } 797 #if H HI_INTER_VIEW_MOTION_PRED797 #if H3D_IVMP 798 798 WRITE_UVLC( pcSPS->getMultiviewMvPredMode(), "multi_view_mv_pred_mode" ); 799 799 #endif … … 1306 1306 } 1307 1307 1308 #if ( HHI_MPI || H HI_INTER_VIEW_MOTION_PRED)1309 #if ( HHI_MPI && H HI_INTER_VIEW_MOTION_PRED)1308 #if ( HHI_MPI || H3D_IVMP ) 1309 #if ( HHI_MPI && H3D_IVMP ) 1310 1310 const int iExtraMergeCandidates = ( pcSlice->getSPS()->getUseMVI() || pcSlice->getSPS()->getMultiviewMvPredMode() ) ? 1 : 0; 1311 1311 #elif HHI_MPI … … 1490 1490 } 1491 1491 1492 #if H HI_INTER_VIEW_MOTION_PRED1492 #if H3D_IVMP 1493 1493 Void TEncCavlc::codeMVPIdx ( TComDataCU* pcCU, UInt uiAbsPartIdx, RefPicList eRefList, Int iNum ) 1494 1494 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCavlc.h
r280 r292 139 139 Void encodeStart () {} 140 140 141 #if H HI_INTER_VIEW_MOTION_PRED141 #if H3D_IVMP 142 142 Void codeMVPIdx ( TComDataCU* pcCU, UInt uiAbsPartIdx, RefPicList eRefList, Int iNum ); 143 143 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCfg.h
r280 r292 352 352 #endif 353 353 354 #if H HI_INTER_VIEW_MOTION_PRED354 #if H3D_IVMP 355 355 UInt m_uiMultiviewMvPredMode; 356 356 UInt m_uiMultiviewMvRegMode; … … 447 447 #endif 448 448 449 #if H HI_INTER_VIEW_MOTION_PRED449 #if H3D_IVMP 450 450 Void setMultiviewMvPredMode ( UInt u ) { m_uiMultiviewMvPredMode = u; } 451 451 Void setMultiviewMvRegMode ( UInt u ) { m_uiMultiviewMvRegMode = u; } … … 482 482 Void setVerticalDisparitySearchRange ( Int i ) { m_iVerticalDisparitySearchRange = i; } 483 483 #endif 484 #if H HI_INTER_VIEW_MOTION_PRED484 #if H3D_IVMP 485 485 UInt getMultiviewMvRegMode () { return m_uiMultiviewMvRegMode; } 486 486 Double getMultiviewMvRegLambdaScale () { return m_dMultiviewMvRegLambdaScale; } -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCu.cpp
r290 r292 1942 1942 { 1943 1943 assert( rpcTempCU->getSlice()->getSliceType() != I_SLICE ); 1944 #if H HI_INTER_VIEW_MOTION_PRED1944 #if H3D_IVMP 1945 1945 TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS_MEM << 1]; // double length for mv of both lists 1946 1946 UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS_MEM]; … … 1959 1959 #endif 1960 1960 1961 #if H HI_INTER_VIEW_MOTION_PRED1961 #if H3D_IVMP 1962 1962 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS_MEM; ++ui ) 1963 1963 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncEntropy.cpp
r287 r292 1508 1508 if ( (pcCU->getInterDir( uiAbsPartIdx ) & ( 1 << eRefList )) && (pcCU->getAMVPMode(uiAbsPartIdx) == AM_EXPL) ) 1509 1509 { 1510 #if H HI_INTER_VIEW_MOTION_PRED1510 #if H3D_IVMP 1511 1511 const Int iNumCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 1512 1512 m_pcEntropyCoderIf->codeMVPIdx( pcCU, uiAbsPartIdx, eRefList, iNumCands ); -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncEntropy.h
r287 r292 103 103 104 104 virtual Void codeAlfCtrlDepth() = 0; 105 #if H HI_INTER_VIEW_MOTION_PRED105 #if H3D_IVMP 106 106 virtual Void codeMVPIdx ( TComDataCU* pcCU, UInt uiAbsPartIdx, RefPicList eRefList, Int iNum ) = 0; 107 107 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncGOP.cpp
r289 r292 758 758 #endif 759 759 #endif 760 #if H HI_INTER_VIEW_MOTION_PRED760 #if H3D_IVMP 761 761 m_pcDepthMapGenerator->covertOrgDepthMap( pcPic ); 762 762 #endif … … 1582 1582 pcPic->removeUsedPelsMapBuffer() ; 1583 1583 #endif 1584 #if H HI_INTER_VIEW_MOTION_PRED1584 #if H3D_IVMP 1585 1585 pcPic->removeOrgDepthMapBuffer(); 1586 1586 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSbac.cpp
r287 r292 600 600 } 601 601 602 #if H HI_INTER_VIEW_MOTION_PRED602 #if H3D_IVMP 603 603 Void TEncSbac::codeMVPIdx ( TComDataCU* pcCU, UInt uiAbsPartIdx, RefPicList eRefList, Int iNum ) 604 604 #else … … 607 607 { 608 608 Int iSymbol = pcCU->getMVPIdx(eRefList, uiAbsPartIdx); 609 #if H HI_INTER_VIEW_MOTION_PRED609 #if H3D_IVMP 610 610 #else 611 611 Int iNum = AMVP_MAX_NUM_CANDS; -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSbac.h
r287 r292 220 220 #endif 221 221 Void codeSplitFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 222 #if H HI_INTER_VIEW_MOTION_PRED222 #if H3D_IVMP 223 223 Void codeMVPIdx ( TComDataCU* pcCU, UInt uiAbsPartIdx, RefPicList eRefList, Int iNum ); 224 224 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSearch.cpp
r290 r292 205 205 #endif 206 206 207 #if H HI_INTER_VIEW_MOTION_PRED207 #if H3D_IVMP 208 208 const Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + 1; 209 209 for( Int iNum = 0; iNum < iNumAMVPCands+1; iNum++) … … 2963 2963 { 2964 2964 #if !CU_BASED_MRG_CAND_LIST 2965 #if H HI_INTER_VIEW_MOTION_PRED2965 #if H3D_IVMP 2966 2966 TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS_MEM << 1]; // double length for mv of both lists 2967 2967 UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS_MEM]; … … 3009 3009 3010 3010 3011 #if H HI_INTER_VIEW_MOTION_PRED3011 #if H3D_IVMP 3012 3012 const int maxNumMergeCand = MRG_MAX_NUM_CANDS_SIGNALED + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 3013 3013 #endif … … 3074 3074 xGetInterPredictionError( pcCU, pcYuvOrg, iPUIdx, uiCostCand, m_pcEncCfg->getUseHADME() ); 3075 3075 uiBitsCand = uiMergeCand + 1; 3076 #if H HI_INTER_VIEW_MOTION_PRED3076 #if H3D_IVMP 3077 3077 if (uiMergeCand == maxNumMergeCand - 1 ) 3078 3078 #else … … 3182 3182 3183 3183 #if CU_BASED_MRG_CAND_LIST 3184 #if H HI_INTER_VIEW_MOTION_PRED3184 #if H3D_IVMP 3185 3185 TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS_MEM << 1]; // double length for mv of both lists 3186 3186 UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS_MEM]; … … 3193 3193 #endif 3194 3194 3195 #if H HI_INTER_VIEW_MOTION_PRED3195 #if H3D_IVMP 3196 3196 Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 3197 3197 #endif … … 3299 3299 #endif 3300 3300 3301 #if H HI_INTER_VIEW_MOTION_PRED3301 #if H3D_IVMP 3302 3302 uiBitsTemp += m_auiMVPIdxCost[aaiMvpIdx[iRefList][iRefIdxTemp]][iNumAMVPCands]; 3303 3303 #else … … 3486 3486 } 3487 3487 3488 #if H HI_INTER_VIEW_MOTION_PRED3488 #if H3D_IVMP 3489 3489 uiMotBits[1] += m_auiMVPIdxCost[aaiMvpIdxBi[1][bestBiPRefIdxL1]][iNumAMVPCands]; 3490 3490 #else … … 3551 3551 if ( iRefIdxTemp == pcCU->getSlice()->getNumRefIdx(eRefPicList)-1 ) uiBitsTemp--; 3552 3552 } 3553 #if H HI_INTER_VIEW_MOTION_PRED3553 #if H3D_IVMP 3554 3554 uiBitsTemp += m_auiMVPIdxCost[aaiMvpIdxBi[iRefList][iRefIdxTemp]][iNumAMVPCands]; 3555 3555 #else … … 4032 4032 if(pcCU->getSlice()->getMvdL1ZeroFlag() && eRefPicList==REF_PIC_LIST_1) 4033 4033 { 4034 #if H HI_INTER_VIEW_MOTION_PRED4034 #if H3D_IVMP 4035 4035 Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 4036 4036 #if ZERO_MVD_EST … … 4068 4068 { 4069 4069 UInt uiTmpCost; 4070 #if H HI_INTER_VIEW_MOTION_PRED4070 #if H3D_IVMP 4071 4071 Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 4072 4072 #if ZERO_MVD_EST … … 4203 4203 Int iBestMVPIdx = riMVPIdx; 4204 4204 4205 #if H HI_INTER_VIEW_MOTION_PRED4205 #if H3D_IVMP 4206 4206 Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 ); 4207 4207 #endif … … 4209 4209 m_pcRdCost->setPredictor( rcMvPred ); 4210 4210 Int iOrgMvBits = m_pcRdCost->getBits(cMv.getHor(), cMv.getVer()); 4211 #if H HI_INTER_VIEW_MOTION_PRED4211 #if H3D_IVMP 4212 4212 iOrgMvBits += m_auiMVPIdxCost[riMVPIdx][iNumAMVPCands]; 4213 4213 #else … … 4223 4223 4224 4224 Int iMvBits = m_pcRdCost->getBits(cMv.getHor(), cMv.getVer()); 4225 #if H HI_INTER_VIEW_MOTION_PRED4225 #if H3D_IVMP 4226 4226 iMvBits += m_auiMVPIdxCost[iMVPIdx][iNumAMVPCands]; 4227 4227 #else … … 4408 4408 m_pcRdCost->setCostScale ( 2 ); 4409 4409 4410 #if H HI_INTER_VIEW_MOTION_PRED4410 #if H3D_IVMP 4411 4411 { // init inter-view regularization 4412 4412 TComMv cOrgDepthMapMv; -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSearch.h
r287 r292 121 121 122 122 // AMVP cost computation 123 #if H HI_INTER_VIEW_MOTION_PRED123 #if H3D_IVMP 124 124 UInt m_auiMVPIdxCost[AMVP_MAX_NUM_CANDS+2][AMVP_MAX_NUM_CANDS+2]; //th array bounds 125 125 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSlice.cpp
r287 r292 409 409 #endif 410 410 411 #if H HI_INTER_VIEW_MOTION_PRED411 #if H3D_IVMP 412 412 m_pcRdCost ->setLambdaMVReg ( dLambda * m_pcCfg->getMultiviewMvRegLambdaScale() ); 413 413 #endif … … 469 469 rpcSlice->setEntropySliceArgument ( m_pcCfg->getEntropySliceArgument() ); 470 470 471 #if ( HHI_MPI || H HI_INTER_VIEW_MOTION_PRED)472 #if ( HHI_MPI && H HI_INTER_VIEW_MOTION_PRED)471 #if ( HHI_MPI || H3D_IVMP ) 472 #if ( HHI_MPI && H3D_IVMP ) 473 473 const int iExtraMergeCandidates = ( pSPS->getUseMVI() || pSPS->getMultiviewMvPredMode() ) ? 1 : 0; 474 474 #elif HHI_MPI … … 582 582 pcSlice ->setLambda ( m_pdRdPicLambda[uiQpIdx] ); 583 583 #endif 584 #if H HI_INTER_VIEW_MOTION_PRED584 #if H3D_IVMP 585 585 m_pcRdCost ->setLambdaMVReg ( m_pdRdPicLambda[uiQpIdx] * m_pcCfg->getMultiviewMvRegLambdaScale() ); 586 586 #endif … … 638 638 pcSlice ->setLambda ( m_pdRdPicLambda[uiQpIdxBest] ); 639 639 #endif 640 #if H HI_INTER_VIEW_MOTION_PRED640 #if H3D_IVMP 641 641 m_pcRdCost ->setLambdaMVReg ( m_pdRdPicLambda[uiQpIdxBest] * m_pcCfg->getMultiviewMvRegLambdaScale() ); 642 642 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncTop.cpp
r280 r292 409 409 pcPicCurr->setScaleOffset( m_aaiCodedScale, m_aaiCodedOffset ); 410 410 411 #if H HI_INTER_VIEW_MOTION_PRED411 #if H3D_IVMP 412 412 if( m_uiMultiviewMvRegMode ) 413 413 { … … 486 486 487 487 488 #if HHI_INTERVIEW_SKIP || H HI_INTER_VIEW_MOTION_PRED|| HHI_INTER_VIEW_RESIDUAL_PRED488 #if HHI_INTERVIEW_SKIP || H3D_IVMP || HHI_INTER_VIEW_RESIDUAL_PRED 489 489 Void 490 490 TEncTop::deleteExtraPicBuffers( Int iPoc ) … … 504 504 if ( pcPic ) 505 505 { 506 #if H HI_INTER_VIEW_MOTION_PRED506 #if H3D_IVMP 507 507 pcPic->removeOrgDepthMapBuffer(); 508 508 #endif … … 594 594 m_iNumPicRcvd++; 595 595 596 #if H HI_INTER_VIEW_MOTION_PRED596 #if H3D_IVMP 597 597 if( m_uiMultiviewMvRegMode ) 598 598 { … … 801 801 { 802 802 #if DEPTH_MAP_GENERATION 803 #if H HI_INTER_VIEW_MOTION_PRED803 #if H3D_IVMP 804 804 m_cSPS.setPredDepthMapGeneration( m_viewId, false, m_uiPredDepthMapGeneration, m_uiMultiviewMvPredMode, m_uiPdmPrecision, m_aaiPdmScaleNomDelta, m_aaiPdmOffset ); 805 805 #else -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncTop.h
r56 r292 173 173 } 174 174 } 175 #if HHI_INTERVIEW_SKIP || H HI_INTER_VIEW_MOTION_PRED|| HHI_INTER_VIEW_RESIDUAL_PRED175 #if HHI_INTERVIEW_SKIP || H3D_IVMP || HHI_INTER_VIEW_RESIDUAL_PRED 176 176 Void deleteExtraPicBuffers ( Int iPoc ); 177 177 #endif
Note: See TracChangeset for help on using the changeset viewer.