Changeset 287 in 3DVCSoftware for branches/HTM-5.1-dev0/source
- Timestamp:
- 17 Feb 2013, 01:49:33 (12 years ago)
- Location:
- branches/HTM-5.1-dev0/source
- Files:
-
- 26 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncCfg.cpp
r280 r287 340 340 ("LoopFilterTcOffset_div2", m_loopFilterTcOffsetDiv2, 0 ) 341 341 #if LGE_ILLUCOMP_B0045 342 #if LGE_ILLUCOMP_DEPTH_C0046 343 ("IlluCompEnable", m_abUseIC, std::vector<Bool>(2, true), "Enable illumination compensation for inter-view prediction") 344 #else 342 345 ("IlluCompEnable", m_bUseIC , true , "Use illumination compensation for inter-view prediction" ) 346 #endif 343 347 #endif 344 348 #if INTER_VIEW_VECTOR_SCALING_C0115 … … 1807 1811 #endif 1808 1812 #if LGE_ILLUCOMP_B0045 1813 #if LGE_ILLUCOMP_DEPTH_C0046 1814 printf("IlluCompEnable: %d %d", m_abUseIC[0] ? 1 : 0, m_abUseIC[1] ? 1 : 0); 1815 #else 1809 1816 printf("IlluCompEnable: %d ", m_bUseIC); 1817 #endif 1810 1818 #endif 1811 1819 #if INTER_VIEW_VECTOR_SCALING_C0115 -
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncCfg.h
r280 r287 170 170 vector<Bool> m_abUseSAO; 171 171 #if LGE_ILLUCOMP_B0045 172 #if LGE_ILLUCOMP_DEPTH_C0046 173 vector<Bool> m_abUseIC; ///< flag for using illumination compensation for inter-view prediction 174 #else 172 175 Bool m_bUseIC; ///< flag for using illumination compensation for inter-view prediction 176 #endif 173 177 #endif 174 178 #if INTER_VIEW_VECTOR_SCALING_C0115 -
branches/HTM-5.1-dev0/source/App/TAppEncoder/TAppEncTop.cpp
r280 r287 318 318 m_acTEncTopList[iViewIdx]->setUseSAO ( m_abUseSAO[0] ); 319 319 #if LGE_ILLUCOMP_B0045 320 #if LGE_ILLUCOMP_DEPTH_C0046 321 m_acTEncTopList[iViewIdx]->setUseIC ( m_abUseIC[0] ); 322 #else 320 323 m_acTEncTopList[iViewIdx]->setUseIC ( m_bUseIC ); 324 #endif 321 325 #endif 322 326 #if INTER_VIEW_VECTOR_SCALING_C0115 -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/ContextTables.h
r189 r287 153 153 #define NUM_DMM_FLAG_CTX 1 ///< number of context models for DMM flag 154 154 #define NUM_DMM_MODE_CTX 1 ///< number of context models for DMM mode 155 #if LGE_DMM3_SIMP_C0044 156 #define NUM_DMM_DATA_CTX 4 ///< number of context models for DMM data 157 #else 155 158 #define NUM_DMM_DATA_CTX 3 ///< number of context models for DMM data 159 #endif 156 160 #endif 157 161 … … 1261 1265 1262 1266 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 1267 #if FIX_DMM_CTX_INIT_C0034 1268 static const UChar 1269 #else 1263 1270 static const Short 1271 #endif 1264 1272 INIT_DMM_FLAG[3][NUM_DMM_FLAG_CTX] = 1265 1273 { … … 1275 1283 }; 1276 1284 1285 #if FIX_DMM_CTX_INIT_C0034 1286 static const UChar 1287 #else 1277 1288 static const Short 1289 #endif 1278 1290 INIT_DMM_MODE[3][NUM_DMM_MODE_CTX] = 1279 1291 { … … 1289 1301 }; 1290 1302 1303 #if FIX_DMM_CTX_INIT_C0034 1304 static const UChar 1305 #else 1291 1306 static const Short 1307 #endif 1292 1308 INIT_DMM_DATA[3][NUM_DMM_DATA_CTX] = 1293 1309 { 1310 #if LGE_DMM3_SIMP_C0044 1311 { 1312 CNU, CNU, CNU, CNU 1313 }, 1314 { 1315 CNU, CNU, CNU, CNU 1316 }, 1317 { 1318 CNU, CNU, CNU, CNU 1319 } 1320 #else 1294 1321 { 1295 1322 CNU, CNU, CNU … … 1301 1328 CNU, CNU, CNU 1302 1329 } 1330 #endif 1303 1331 }; 1304 1332 -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDataCU.cpp
r280 r287 207 207 #if HHI_DMM_PRED_TEX 208 208 m_puiWedgePredTexTabIdx = NULL; 209 #if LGE_DMM3_SIMP_C0044 210 m_puiWedgePredTexIntraTabIdx = NULL; 211 #endif 209 212 m_piWedgePredTexDeltaDC1 = NULL; 210 213 m_piWedgePredTexDeltaDC2 = NULL; … … 358 361 #if HHI_DMM_PRED_TEX 359 362 m_puiWedgePredTexTabIdx = (UInt*)xMalloc(UInt, uiNumPartition); 363 #if LGE_DMM3_SIMP_C0044 364 m_puiWedgePredTexIntraTabIdx = (UInt*)xMalloc(UInt, uiNumPartition); 365 #endif 360 366 m_piWedgePredTexDeltaDC1 = (Int* )xMalloc(Int, uiNumPartition); 361 367 m_piWedgePredTexDeltaDC2 = (Int* )xMalloc(Int, uiNumPartition); … … 486 492 #if HHI_DMM_PRED_TEX 487 493 if ( m_puiWedgePredTexTabIdx ) { xFree(m_puiWedgePredTexTabIdx ); m_puiWedgePredTexTabIdx = NULL; } 494 #if LGE_DMM3_SIMP_C0044 495 if ( m_puiWedgePredTexIntraTabIdx ) { xFree(m_puiWedgePredTexIntraTabIdx); m_puiWedgePredTexIntraTabIdx = NULL; } 496 #endif 488 497 if ( m_piWedgePredTexDeltaDC1 ) { xFree(m_piWedgePredTexDeltaDC1 ); m_piWedgePredTexDeltaDC1 = NULL; } 489 498 if ( m_piWedgePredTexDeltaDC2 ) { xFree(m_piWedgePredTexDeltaDC2 ); m_piWedgePredTexDeltaDC2 = NULL; } … … 702 711 #if HHI_DMM_PRED_TEX 703 712 memset( m_puiWedgePredTexTabIdx + firstElement, 0, sizeof( UInt ) * numElements ); 713 #if LGE_DMM3_SIMP_C0044 714 memset( m_puiWedgePredTexIntraTabIdx + firstElement, 0, sizeof( UInt ) * numElements ); 715 #endif 704 716 memset( m_piWedgePredTexDeltaDC1 + firstElement, 0, sizeof( Int ) * numElements ); 705 717 memset( m_piWedgePredTexDeltaDC2 + firstElement, 0, sizeof( Int ) * numElements ); … … 890 902 #if HHI_DMM_PRED_TEX 891 903 m_puiWedgePredTexTabIdx [ui] = 0; 904 #if LGE_DMM3_SIMP_C0044 905 m_puiWedgePredTexIntraTabIdx [ui] = 0; 906 #endif 892 907 m_piWedgePredTexDeltaDC1 [ui] = 0; 893 908 m_piWedgePredTexDeltaDC2 [ui] = 0; … … 1014 1029 #if HHI_DMM_PRED_TEX 1015 1030 memset( m_puiWedgePredTexTabIdx, 0, sizeof( UInt ) * m_uiNumPartition ); 1031 #if LGE_DMM3_SIMP_C0044 1032 memset( m_puiWedgePredTexIntraTabIdx, 0, sizeof( UInt ) * m_uiNumPartition ); 1033 #endif 1016 1034 memset( m_piWedgePredTexDeltaDC1, 0, sizeof( Int ) * m_uiNumPartition ); 1017 1035 memset( m_piWedgePredTexDeltaDC2, 0, sizeof( Int ) * m_uiNumPartition ); … … 1088 1106 #if HHI_DMM_PRED_TEX 1089 1107 m_puiWedgePredTexTabIdx [ui]=pcCU->getWedgePredTexTabIdx (uiPartOffset+ui); 1108 #if LGE_DMM3_SIMP_C0044 1109 m_puiWedgePredTexIntraTabIdx [ui]=pcCU->getWedgePredTexIntraTabIdx (uiPartOffset+ui); 1110 #endif 1090 1111 m_piWedgePredTexDeltaDC1 [ui]=pcCU->getWedgePredTexDeltaDC1 (uiPartOffset+ui); 1091 1112 m_piWedgePredTexDeltaDC2 [ui]=pcCU->getWedgePredTexDeltaDC2 (uiPartOffset+ui); … … 1292 1313 #if HHI_DMM_PRED_TEX 1293 1314 m_puiWedgePredTexTabIdx = pcCU->getWedgePredTexTabIdx() + uiPart; 1315 #if LGE_DMM3_SIMP_C0044 1316 m_puiWedgePredTexIntraTabIdx = pcCU->getWedgePredTexIntraTabIdx() + uiPart; 1317 #endif 1294 1318 m_piWedgePredTexDeltaDC1 = pcCU->getWedgePredTexDeltaDC1() + uiPart; 1295 1319 m_piWedgePredTexDeltaDC2 = pcCU->getWedgePredTexDeltaDC2() + uiPart; … … 1483 1507 #if HHI_DMM_PRED_TEX 1484 1508 memcpy( m_puiWedgePredTexTabIdx + uiOffset, pcCU->getWedgePredTexTabIdx(), sizeof( UInt ) * uiNumPartition ); 1509 #if LGE_DMM3_SIMP_C0044 1510 memcpy( m_puiWedgePredTexIntraTabIdx + uiOffset, pcCU->getWedgePredTexIntraTabIdx(), sizeof( UInt ) * uiNumPartition ); 1511 #endif 1485 1512 memcpy( m_piWedgePredTexDeltaDC1 + uiOffset, pcCU->getWedgePredTexDeltaDC1(), sizeof( Int ) * uiNumPartition ); 1486 1513 memcpy( m_piWedgePredTexDeltaDC2 + uiOffset, pcCU->getWedgePredTexDeltaDC2(), sizeof( Int ) * uiNumPartition ); … … 1615 1642 #if HHI_DMM_PRED_TEX 1616 1643 memcpy( rpcCU->getWedgePredTexTabIdx() + m_uiAbsIdxInLCU, m_puiWedgePredTexTabIdx, sizeof( UInt ) * m_uiNumPartition ); 1644 #if LGE_DMM3_SIMP_C0044 1645 memcpy( rpcCU->getWedgePredTexIntraTabIdx() + m_uiAbsIdxInLCU, m_puiWedgePredTexIntraTabIdx, sizeof( UInt ) * m_uiNumPartition ); 1646 #endif 1617 1647 memcpy( rpcCU->getWedgePredTexDeltaDC1() + m_uiAbsIdxInLCU, m_piWedgePredTexDeltaDC1, sizeof( Int ) * m_uiNumPartition ); 1618 1648 memcpy( rpcCU->getWedgePredTexDeltaDC2() + m_uiAbsIdxInLCU, m_piWedgePredTexDeltaDC2, sizeof( Int ) * m_uiNumPartition ); … … 1748 1778 #if HHI_DMM_PRED_TEX 1749 1779 memcpy( rpcCU->getWedgePredTexTabIdx() + uiPartOffset, m_puiWedgePredTexTabIdx, sizeof( UInt ) * uiQNumPart ); 1780 #if LGE_DMM3_SIMP_C0044 1781 memcpy( rpcCU->getWedgePredTexIntraTabIdx() + uiPartOffset, m_puiWedgePredTexIntraTabIdx, sizeof( UInt ) * uiQNumPart ); 1782 #endif 1750 1783 memcpy( rpcCU->getWedgePredTexDeltaDC1() + uiPartOffset, m_piWedgePredTexDeltaDC1, sizeof( Int ) * uiQNumPart ); 1751 1784 memcpy( rpcCU->getWedgePredTexDeltaDC2() + uiPartOffset, m_piWedgePredTexDeltaDC2, sizeof( Int ) * uiQNumPart ); … … 3190 3223 } 3191 3224 3225 #if LGE_ILLUCOMP_DEPTH_C0046 3226 //This modification is not needed after integrating JCT3V-C0137 3227 Bool TComDataCU::isICFlagRequired(UInt uiAbsPartIdx, UInt uiDepth) 3228 { 3229 UInt uiPartAddr; 3230 UInt iNumbPart; 3231 3232 if(!getSlice()->getIsDepth()) 3233 { 3234 Int iWidth, iHeight; 3235 3236 iNumbPart = ( getPartitionSize(uiAbsPartIdx) == SIZE_2Nx2N ? 1 : (getPartitionSize(uiAbsPartIdx) == SIZE_NxN ? 4 : 2) ); 3237 3238 for(UInt i = 0; i < iNumbPart; i++) 3239 { 3240 getPartIndexAndSize(i, uiPartAddr, iWidth, iHeight, uiAbsPartIdx, true); 3241 uiPartAddr += uiAbsPartIdx; 3242 3243 for(UInt uiRefIdx = 0; uiRefIdx < 2; uiRefIdx++) 3244 { 3245 RefPicList eRefList = uiRefIdx ? REF_PIC_LIST_1 : REF_PIC_LIST_0; 3246 Int iBestRefIdx = getCUMvField(eRefList)->getRefIdx(uiPartAddr); 3247 3248 if((getInterDir(uiPartAddr) & (uiRefIdx+1)) && iBestRefIdx >= 0 && getSlice()->getViewId() != getSlice()->getRefViewId(eRefList, iBestRefIdx)) 3249 { 3250 return true; 3251 } 3252 } 3253 } 3254 } 3255 else 3256 { 3257 iNumbPart = getPic()->getNumPartInCU() >> (uiDepth << 1); 3258 3259 for(UInt i = 0; i < iNumbPart; i++) 3260 { 3261 uiPartAddr = uiAbsPartIdx + i; 3262 3263 for(UInt uiRefIdx = 0; uiRefIdx < 2; uiRefIdx++) 3264 { 3265 RefPicList eRefList = uiRefIdx ? REF_PIC_LIST_1 : REF_PIC_LIST_0; 3266 Int iBestRefIdx = getCUMvField(eRefList)->getRefIdx(uiPartAddr); 3267 3268 if((getInterDir(uiPartAddr) & (uiRefIdx+1)) && iBestRefIdx >= 0 && getSlice()->getViewId() != getSlice()->getRefViewId(eRefList, iBestRefIdx)) 3269 { 3270 return true; 3271 } 3272 } 3273 } 3274 } 3275 3276 return false; 3277 } 3278 #else 3192 3279 Bool TComDataCU::isICFlagRequired(UInt uiAbsPartIdx) 3193 3280 { … … 3211 3298 3212 3299 if((getInterDir(uiPartAddr) & (uiRefIdx+1)) && iBestRefIdx >= 0 && getSlice()->getViewId() != getSlice()->getRefViewId(eRefList, iBestRefIdx)) 3300 { 3213 3301 return true; 3214 3302 } 3215 3303 } 3304 } 3216 3305 return false; 3217 3306 } 3307 #endif 3218 3308 #endif 3219 3309 … … 8925 9015 } 8926 9016 9017 #if LGE_DMM3_SIMP_C0044 9018 Void TComDataCU::setWedgePredTexIntraTabIdxSubParts( UInt uiTIdx, UInt uiAbsPartIdx, UInt uiDepth ) 9019 { 9020 UInt uiCurrPartNumb = m_pcPic->getNumPartInCU() >> (uiDepth << 1); 9021 9022 for ( UInt ui = 0; ui < uiCurrPartNumb; ui++ ) 9023 { 9024 m_puiWedgePredTexIntraTabIdx[uiAbsPartIdx+ui] = uiTIdx; 9025 } 9026 } 9027 #endif 9028 8927 9029 Void TComDataCU::setWedgePredTexDeltaDC1SubParts( Int iDC1, UInt uiAbsPartIdx, UInt uiDepth ) 8928 9030 { -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComDataCU.h
r280 r287 266 266 #if HHI_DMM_PRED_TEX 267 267 UInt* m_puiWedgePredTexTabIdx; 268 #if LGE_DMM3_SIMP_C0044 269 UInt* m_puiWedgePredTexIntraTabIdx; 270 #endif 268 271 Int* m_piWedgePredTexDeltaDC1; 269 272 Int* m_piWedgePredTexDeltaDC2; … … 500 503 Void setICFlag ( UInt uiIdx, Bool uh ) { m_pbICFlag[uiIdx] = uh; } 501 504 Void setICFlagSubParts ( Bool bICFlag, UInt uiAbsPartIdx, UInt uiPartIdx, UInt uiDepth ); 505 #if LGE_ILLUCOMP_DEPTH_C0046 506 Bool isICFlagRequired (UInt uiAbsPartIdx, UInt uiDepth); //This modification is not needed after integrating JCT3V-C0137 507 #else 502 508 Bool isICFlagRequired (UInt uiAbsPartIdx); 509 #endif 503 510 #endif 504 511 … … 838 845 Void setWedgePredTexTabIdx ( UInt uiIdx, UInt uh ) { m_puiWedgePredTexTabIdx[uiIdx] = uh; } 839 846 Void setWedgePredTexTabIdxSubParts ( UInt uiTIdx, UInt uiAbsPartIdx, UInt uiDepth ); 847 #if LGE_DMM3_SIMP_C0044 848 UInt* getWedgePredTexIntraTabIdx () { return m_puiWedgePredTexIntraTabIdx; } 849 UInt getWedgePredTexIntraTabIdx ( UInt uiIdx ) { return m_puiWedgePredTexIntraTabIdx[uiIdx]; } 850 Void setWedgePredTexIntraTabIdx ( UInt uiIdx, UInt uh ) { m_puiWedgePredTexIntraTabIdx[uiIdx] = uh; } 851 Void setWedgePredTexIntraTabIdxSubParts ( UInt uiTIdx, UInt uiAbsPartIdx, UInt uiDepth ); 852 #endif 840 853 Int* getWedgePredTexDeltaDC1 () { return m_piWedgePredTexDeltaDC1; } 841 854 Int getWedgePredTexDeltaDC1 ( UInt uiIdx ) { return m_piWedgePredTexDeltaDC1[uiIdx]; } -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComPrediction.cpp
r280 r287 949 949 UInt uiRShift = ( bi ? 14-g_uiBitDepth-g_uiBitIncrement : 0 ); 950 950 UInt uiOffset = bi ? IF_INTERNAL_OFFS : 0; 951 #if LGE_ILLUCOMP_DEPTH_C0046 952 Bool bICFlag = pcCU->getICFlag(uiPartAddr) && (pcCU->getSlice()->getRefViewId( eRefPicList, iRefIdx ) != pcCU->getSlice()->getViewId()); 953 #endif 951 954 #if DEPTH_MAP_GENERATION 952 xPredInterPrdDepthMap( pcCU, pcCU->getSlice()->getRefPic( eRefPicList, iRefIdx )->getPicYuvRec(), uiPartAddr, &cMv, iWidth, iHeight, 0, 0, rpcYuvPred, uiRShift, uiOffset ); 955 xPredInterPrdDepthMap( pcCU, pcCU->getSlice()->getRefPic( eRefPicList, iRefIdx )->getPicYuvRec(), uiPartAddr, &cMv, iWidth, iHeight, 0, 0, rpcYuvPred, uiRShift, uiOffset 956 #if LGE_ILLUCOMP_DEPTH_C0046 957 , bICFlag 958 #endif 959 ); 953 960 #else 954 961 xPredInterPrdDepthMap( pcCU, pcCU->getSlice()->getRefPic( eRefPicList, iRefIdx )->getPicYuvRec(), uiPartAddr, &cMv, iWidth, iHeight, rpcYuvPred, uiRShift, uiOffset ); … … 1152 1159 Void 1153 1160 #if DEPTH_MAP_GENERATION 1154 TComPrediction::xPredInterPrdDepthMap( TComDataCU* pcCU, TComPicYuv* pcPicYuvRef, UInt uiPartAddr, TComMv* pcMv, Int iWidth, Int iHeight, UInt uiSubSampExpX, UInt uiSubSampExpY, TComYuv*& rpcYuv, UInt uiRShift, UInt uiOffset ) 1161 TComPrediction::xPredInterPrdDepthMap( TComDataCU* pcCU, TComPicYuv* pcPicYuvRef, UInt uiPartAddr, TComMv* pcMv, Int iWidth, Int iHeight, UInt uiSubSampExpX, UInt uiSubSampExpY, TComYuv*& rpcYuv, UInt uiRShift, UInt uiOffset 1162 #if LGE_ILLUCOMP_DEPTH_C0046 1163 , Bool bICFlag 1164 #endif 1165 ) 1155 1166 #else 1156 1167 TComPrediction::xPredInterPrdDepthMap( TComDataCU* pcCU, TComPicYuv* pcPicYuvRef, UInt uiPartAddr, TComMv* pcMv, Int iWidth, Int iHeight, TComYuv*& rpcYuv, UInt uiRShift, UInt uiOffset ) … … 1204 1215 } 1205 1216 } 1217 1218 #if LGE_ILLUCOMP_DEPTH_C0046 1219 if(bICFlag) 1220 { 1221 Int a, b, iShift; 1222 TComMv tTmpMV(pcMv->getHor()<<2, pcMv->getVer()<<2); 1223 1224 piRefY = pcPicYuvRef->getLumaAddr( pcCU->getAddr(), pcCU->getZorderIdxInCU() + uiPartAddr ) + iRefOffset; 1225 piDstY = rpcYuv->getLumaAddr( uiPartAddr ); 1226 1227 xGetLLSICPrediction(pcCU, &tTmpMV, pcPicYuvRef, a, b, iShift); 1228 1229 for( Int y = 0; y < iHeight; y++, piDstY += iDstStride, piRefY += iRefStride ) 1230 { 1231 for( Int x = 0; x < iWidth; x++ ) 1232 { 1233 if(uiOffset) 1234 { 1235 Int iIFshift = IF_INTERNAL_PREC - ( g_uiBitDepth + g_uiBitIncrement ); 1236 piDstY[ x ] = ( (a*piDstY[ x ]+a*IF_INTERNAL_OFFS) >> iShift ) + b*(1<<iIFshift) - IF_INTERNAL_OFFS; 1237 } 1238 else 1239 piDstY[ x ] = Clip( ( (a*piDstY[ x ]) >> iShift ) + b ); 1240 } 1241 } 1242 } 1243 #endif 1206 1244 } 1207 1245 … … 2339 2377 iCUPelX = pcCU->getCUPelX() + g_auiRasterToPelX[g_auiZscanToRaster[pcCU->getZorderIdxInCU()]]; 2340 2378 iCUPelY = pcCU->getCUPelY() + g_auiRasterToPelY[g_auiZscanToRaster[pcCU->getZorderIdxInCU()]]; 2379 #if FIX_LGE_ILLUCOMP_B0045 2380 iRefX = iCUPelX + (pMv->getHor() >> 2); 2381 iRefY = iCUPelY + (pMv->getVer() >> 2); 2382 #else 2341 2383 iRefX = iCUPelX + (pMv->getHor() >> 3); 2342 2384 iRefY = iCUPelY + (pMv->getVer() >> 3); 2385 #endif 2343 2386 uiWidth = pcCU->getWidth(0) >> 1; 2344 2387 uiHeight = pcCU->getHeight(0) >> 1; … … 2554 2597 UInt uiWedgeStride = pcWedgelet->getStride(); 2555 2598 2599 #if HS_REFERENCE_SUBSAMPLE_C0154 2600 Int subSamplePix; 2601 if ( pcWedgelet->getWidth() == 32 ) 2602 { 2603 subSamplePix = 2; 2604 } 2605 else 2606 { 2607 subSamplePix = 1; 2608 } 2609 #endif 2610 2556 2611 if( bAbove ) 2557 2612 { 2613 #if HS_REFERENCE_SUBSAMPLE_C0154 2614 for( Int k = 0; k < pcWedgelet->getWidth(); k+=subSamplePix ) 2615 #else 2558 2616 for( Int k = 0; k < pcWedgelet->getWidth(); k++ ) 2617 #endif 2559 2618 { 2560 2619 if( true == pabWedgePattern[k] ) … … 2572 2631 if( bLeft ) 2573 2632 { 2633 #if HS_REFERENCE_SUBSAMPLE_C0154 2634 for( Int k = 0; k < pcWedgelet->getHeight(); k+=subSamplePix ) 2635 #else 2574 2636 for( Int k = 0; k < pcWedgelet->getHeight(); k++ ) 2637 #endif 2575 2638 { 2576 2639 if( true == pabWedgePattern[k*uiWedgeStride] ) … … 2751 2814 } 2752 2815 2816 #if LGE_DMM3_SIMP_C0044 2817 /** 2818 - fetch best Wedgelet pattern at decoder 2819 */ 2820 UInt TComPrediction::getBestWedgeFromTex( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, UInt IntraTabIdx) 2821 { 2822 assert( uiWidth >= DMM_WEDGEMODEL_MIN_SIZE && uiWidth <= DMM_WEDGEMODEL_MAX_SIZE ); 2823 2824 UInt uiBestTabIdx = 0; 2825 TComPic* pcPicTex = pcCU->getSlice()->getTexturePic(); 2826 TComDataCU* pcColTexCU = pcPicTex->getCU(pcCU->getAddr()); 2827 UInt uiTexPartIdx = pcCU->getZorderIdxInCU() + uiAbsPartIdx; 2828 Int uiColTexIntraDir = pcColTexCU->isIntra( uiTexPartIdx ) ? pcColTexCU->getLumaIntraDir( uiTexPartIdx ) : 255; 2829 2830 std::vector< std::vector<UInt> > pauiWdgLstSz = g_aauiWdgLstM3[g_aucConvertToBit[uiWidth]]; 2831 2832 if( uiColTexIntraDir > DC_IDX && uiColTexIntraDir < 35 ) 2833 { 2834 std::vector<UInt>* pauiWdgLst = &pauiWdgLstSz[uiColTexIntraDir-2]; 2835 uiBestTabIdx = pauiWdgLst->at(IntraTabIdx); 2836 } 2837 else 2838 { 2839 WedgeNodeList* pacWedgeNodeList = &g_aacWedgeNodeLists[(g_aucConvertToBit[uiWidth])]; 2840 uiBestTabIdx = pacWedgeNodeList->at(IntraTabIdx).getPatternIdx(); 2841 } 2842 2843 return uiBestTabIdx; 2844 } 2845 #endif 2846 2847 #if LGE_DMM3_SIMP_C0044 2848 /** 2849 - calculate best Wedgelet pattern at encoder 2850 */ 2851 UInt TComPrediction::getBestWedgeFromTex( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, Pel* piOrigi, UInt uiStride, UInt & ruiIntraTabIdx) 2852 #else 2753 2853 UInt TComPrediction::getBestWedgeFromTex( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight ) 2854 #endif 2754 2855 { 2755 2856 assert( uiWidth >= DMM_WEDGEMODEL_MIN_SIZE && uiWidth <= DMM_WEDGEMODEL_MAX_SIZE ); … … 2779 2880 Int iDC2 = 0; 2780 2881 WedgeList* pacWedgeList = &g_aacWedgeLists[(g_aucConvertToBit[uiWidth])]; 2781 2882 #if LGE_DMM3_SIMP_C0044 2883 ruiIntraTabIdx = 0; 2884 #endif 2782 2885 #if HHIQC_DMMFASTSEARCH_B0039 2783 2886 TComPic* pcPicTex = pcCU->getSlice()->getTexturePic(); … … 2793 2896 { 2794 2897 UInt uiIdx = pauiWdgLst->at(uiIdxW); 2898 #if LGE_DMM3_SIMP_C0044 2899 calcWedgeDCs ( &(pacWedgeList->at(uiIdx)), piOrigi, uiWidth, iDC1, iDC2 ); 2900 #else 2795 2901 calcWedgeDCs ( &(pacWedgeList->at(uiIdx)), piRefBlkY, uiWidth, iDC1, iDC2 ); 2902 #endif 2796 2903 assignWedgeDCs2Pred( &(pacWedgeList->at(uiIdx)), piPred, uiPredStride, iDC1, iDC2 ); 2797 2904 2905 #if LGE_DMM3_SIMP_C0044 2906 UInt uiActDist = cWedgeDist.getDistPart( piPred, uiPredStride, piOrigi, uiStride, uiWidth, uiHeight, WedgeDist_SAD ); 2907 #else 2798 2908 UInt uiActDist = cWedgeDist.getDistPart( piPred, uiPredStride, piRefBlkY, uiWidth, uiWidth, uiHeight, WedgeDist_SAD ); 2909 #endif 2799 2910 2800 2911 if( uiActDist < uiBestDist || uiBestDist == MAX_UINT ) … … 2802 2913 uiBestDist = uiActDist; 2803 2914 uiBestTabIdx = uiIdx; 2915 #if LGE_DMM3_SIMP_C0044 2916 ruiIntraTabIdx = uiIdxW; 2917 #endif 2804 2918 } 2805 2919 } … … 2812 2926 for( UInt uiNodeId = 0; uiNodeId < pacWedgeNodeList->size(); uiNodeId++ ) 2813 2927 { 2928 #if LGE_DMM3_SIMP_C0044 2929 calcWedgeDCs ( &(pacWedgeList->at(pacWedgeNodeList->at(uiNodeId).getPatternIdx())), piOrigi, uiWidth, iDC1, iDC2 ); 2930 #else 2814 2931 calcWedgeDCs ( &(pacWedgeList->at(pacWedgeNodeList->at(uiNodeId).getPatternIdx())), piRefBlkY, uiWidth, iDC1, iDC2 ); 2932 #endif 2815 2933 assignWedgeDCs2Pred( &(pacWedgeList->at(pacWedgeNodeList->at(uiNodeId).getPatternIdx())), piPred, uiPredStride, iDC1, iDC2 ); 2816 2934 2935 #if LGE_DMM3_SIMP_C0044 2936 UInt uiActDist = cWedgeDist.getDistPart( piPred, uiPredStride, piOrigi, uiStride, uiWidth, uiHeight, WedgeDist_SAD ); 2937 #else 2817 2938 UInt uiActDist = cWedgeDist.getDistPart( piPred, uiPredStride, piRefBlkY, uiWidth, uiWidth, uiHeight, WedgeDist_SAD ); 2939 #endif 2818 2940 2819 2941 if( uiActDist < uiBestNodeDist || uiBestNodeDist == MAX_UINT ) … … 2821 2943 uiBestNodeDist = uiActDist; 2822 2944 uiBestNodeId = uiNodeId; 2823 } 2824 } 2825 2945 #if LGE_DMM3_SIMP_C0044 2946 ruiIntraTabIdx = uiNodeId; 2947 #endif 2948 } 2949 } 2950 #if LGE_DMM3_SIMP_C0044 2951 uiBestTabIdx = pacWedgeNodeList->at(uiBestNodeId).getPatternIdx(); 2952 #else 2826 2953 // refinement 2827 2954 uiBestDist = uiBestNodeDist; … … 2843 2970 } 2844 2971 } 2972 #endif 2845 2973 } 2846 2974 #else … … 2897 3025 { 2898 3026 // decoder: get and store wedge pattern in CU 3027 // decoder: get and store wedge pattern in CU 3028 #if LGE_DMM3_SIMP_C0044 3029 UInt uiIntraTabIdx = pcCU->getWedgePredTexIntraTabIdx ( uiAbsPartIdx ); 3030 uiTextureWedgeTabIdx = getBestWedgeFromTex( pcCU, uiAbsPartIdx, (UInt)iWidth, (UInt)iHeight, uiIntraTabIdx ); 3031 #else 2899 3032 uiTextureWedgeTabIdx = getBestWedgeFromTex( pcCU, uiAbsPartIdx, (UInt)iWidth, (UInt)iHeight ); 3033 #endif 2900 3034 2901 3035 UInt uiDepth = (pcCU->getDepth(0)) + (pcCU->getPartitionSize(0) == SIZE_2Nx2N ? 0 : 1); … … 2912 3046 getWedgePredDCs( pcWedgelet, piMask, iMaskStride, iPredDC1, iPredDC2, bAbove, bLeft ); 2913 3047 3048 #if HHI_DMM_DELTADC_Q1_C0034 3049 #else 2914 3050 if( bDelta ) 2915 3051 { … … 2917 3053 xDeltaDCQuantScaleUp( pcCU, iDeltaDC2 ); 2918 3054 } 3055 #endif 2919 3056 2920 3057 // assign wedge pred DCs to prediction … … 2937 3074 getWedgePredDCs( pcContourWedge, piMask, iMaskStride, iPredDC1, iPredDC2, bAbove, bLeft ); 2938 3075 3076 #if HHI_DMM_DELTADC_Q1_C0034 3077 #else 2939 3078 if( bDelta ) 2940 3079 { … … 2942 3081 xDeltaDCQuantScaleUp( pcCU, iDeltaDC2 ); 2943 3082 } 3083 #endif 2944 3084 2945 3085 // assign wedge pred DCs to prediction … … 3118 3258 getWedgePredDCs( pcWedgelet, piMask, iMaskStride, iPredDC1, iPredDC2, bAbove, bLeft ); 3119 3259 3260 #if HHI_DMM_DELTADC_Q1_C0034 3261 #else 3120 3262 if( bDelta ) 3121 3263 { … … 3123 3265 xDeltaDCQuantScaleUp( pcCU, iDeltaDC2 ); 3124 3266 } 3267 #endif 3125 3268 3126 3269 // assign wedge pred DCs to prediction … … 3159 3302 getWedgePredDCs( pcWedgelet, piMask, iMaskStride, iPredDC1, iPredDC2, bAbove, bLeft ); 3160 3303 3304 #if HHI_DMM_DELTADC_Q1_C0034 3305 #else 3161 3306 if( bDelta ) 3162 3307 { … … 3164 3309 xDeltaDCQuantScaleUp( pcCU, iDeltaDC2 ); 3165 3310 } 3311 #endif 3166 3312 3167 3313 // assign wedge pred DCs to prediction -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComPrediction.h
r280 r287 106 106 Void xPredInterBi ( TComDataCU* pcCU, UInt uiPartAddr, Int iWidth, Int iHeight, UInt uiSubSampExpX, UInt uiSubSampExpY, TComYuv*& rpcYuvPred, Int iPartIdx, Bool bPrdDepthMap ); 107 107 #endif 108 Void xPredInterPrdDepthMap ( TComDataCU* pcCU, TComPicYuv* pcPicYuvRef, UInt uiPartAddr, TComMv* pcMv, Int iWidth, Int iHeight, UInt uiSubSampExpX, UInt uiSubSampExpY, TComYuv*& rpcYuv, UInt uiRShift, UInt uiOffset ); 108 Void xPredInterPrdDepthMap ( TComDataCU* pcCU, TComPicYuv* pcPicYuvRef, UInt uiPartAddr, TComMv* pcMv, Int iWidth, Int iHeight, UInt uiSubSampExpX, UInt uiSubSampExpY, TComYuv*& rpcYuv, UInt uiRShift, UInt uiOffset 109 #if LGE_ILLUCOMP_DEPTH_C0046 110 , Bool bICFlag = false 111 #endif 112 ); 109 113 #else 110 114 #if MERL_VSP_C0152 … … 218 222 #if HHI_DMM_PRED_TEX 219 223 Void getBestContourFromTex ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, TComWedgelet* pcContourWedge ); 224 #if LGE_DMM3_SIMP_C0044 225 UInt getBestWedgeFromTex ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, Pel * piOrgi, UInt uiStride, UInt &ruiIntraTabIdx);//encoder 226 UInt getBestWedgeFromTex ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, UInt IntraTabIdx);//decoder 227 #else 220 228 UInt getBestWedgeFromTex ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight ); 229 #endif 221 230 Void copyTextureLumaBlock ( TComDataCU* pcCU, UInt uiAbsPartIdx, Pel* piDestBlockY, UInt uiWidth, UInt uiHeight ); 222 231 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComRom.cpp
r189 r287 306 306 307 307 #if RWTH_SDC_DLT_B0036 308 #if SAIT_SDC_C0096 309 UInt g_auiSDCPredModes[RWTH_SDC_NUM_PRED_MODES] = { DC_IDX, DMM_WEDGE_FULL_IDX, PLANAR_IDX }; 310 #else 308 311 UInt g_auiSDCPredModes[RWTH_SDC_NUM_PRED_MODES] = { DC_IDX, DMM_WEDGE_FULL_IDX, DMM_WEDGE_PREDDIR_IDX, PLANAR_IDX }; 312 #endif 309 313 #endif 310 314 … … 587 591 }; 588 592 593 #if LGE_DMM3_SIMP_C0044 594 const UChar g_aucWedgeTexPredBitsListIdx[7] = 595 { 596 0, // 2x2 597 6, // 4x4 598 9, // 8x8 599 9, // 16x16 600 9, // 32x32 601 0, // 64x64 602 0 // 128x128 603 }; 604 #endif 605 589 606 const UChar g_aucIntraSizeIdxToWedgeSize[7] = 590 607 { -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComRom.h
r189 r287 188 188 extern const WedgeResolution g_aeWedgeResolutionList[5]; 189 189 extern const UChar g_aucWedgeFullBitsListIdx[7]; 190 #if LGE_DMM3_SIMP_C0044 191 extern const UChar g_aucWedgeTexPredBitsListIdx[7]; 192 #endif 190 193 extern const UChar g_aucIntraSizeIdxToWedgeSize[7]; 191 194 … … 199 202 200 203 #if RWTH_SDC_DLT_B0036 204 #if SAIT_SDC_C0096 205 #define RWTH_SDC_NUM_PRED_MODES 3 206 #else 201 207 #define RWTH_SDC_NUM_PRED_MODES 4 208 #endif 202 209 extern UInt g_auiSDCPredModes[RWTH_SDC_NUM_PRED_MODES]; 203 210 #endif -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TComSlice.cpp
r280 r287 1408 1408 Int iRefStride = pcRefPicYuvOrg->getStride(); 1409 1409 Int iSumOrgSAD = 0; 1410 #if LGE_ILLUCOMP_DEPTH_C0046 1411 Double dThresholdOrgSAD = getIsDepth() ? 0.1 : 0.05; 1412 #else 1410 1413 double dThresholdOrgSAD = 0.05; 1414 #endif 1411 1415 // Histogram building - luminance 1412 1416 for ( Int y = 0; y < iHeight; y++) -
branches/HTM-5.1-dev0/source/Lib/TLibCommon/TypeDef.h
r284 r287 71 71 #define FIX_LGE_DVMCP_B0133 1 72 72 73 // 3rd meeting 74 #define FIX_DMM_CTX_INIT_C0034 1 // JCT3V-C0034 fix for wrong init type of DMM contexts (UChar instead of Short) 75 #define FIX_SDC_ENC_C0143 1 // JCT3V-C0143 fix for unnecessary encoder checks in case of SDC 73 76 74 77 // FCO … … 88 91 #define RWTH_SDC_DLT_B0036 1 // JCT3V-B0036: Simplified Depth Coding + Depth Lookup Table 89 92 #define HHIQC_DMMFASTSEARCH_B0039 1 // JCT3V-B0039: fast Wedgelet search for DMM modes 1 and 3 93 #define HHI_DMM_DELTADC_Q1_C0034 1 // JCT3V-C0034: no quantization and fast encoder search for DMM delta DC values 94 #if HHIQC_DMMFASTSEARCH_B0039 && HHI_DMM_PRED_TEX 95 #define LGE_DMM3_SIMP_C0044 1 96 #endif 97 98 #if RWTH_SDC_DLT_B0036 99 #define SAIT_SDC_C0096 1 // JCT3V-C0096: Improved Simple Depth Coding(removal of DMM2 among four SDC modes(DC, Planar, DMM1 and DMM2)) 100 #endif 90 101 91 102 ///// ***** INTERVIEW MOTION VECTOR PREDICTION ********* … … 147 158 #if LGE_ILLUCOMP_B0045 148 159 #define LGE_ILLUCOMP_B0045_ENCSIMP 1 160 #define FIX_LGE_ILLUCOMP_B0045 1 161 #define LGE_ILLUCOMP_DEPTH_C0046 1 // JCT2-C0046 Apply illumination compensation to depth 162 #if LGE_ILLUCOMP_DEPTH_C0046 163 #define FIX_ILLUCOMP_DEPTH 1 164 #endif 149 165 #endif 150 166 … … 154 170 ///// ***** QUADTREE LIMITATION ********* 155 171 #define OL_QTLIMIT_PREDCODING_B0068 1 //JCT3V-B0068 172 #define HHI_QTLPC_RAU_OFF_C0160 1 // JCT3V-C0160 change 2: quadtree limitation and predictive coding switched off in random access units 156 173 157 174 ///// ***** OTHERS ********* … … 161 178 #define HHI_FULL_PEL_DEPTH_MAP_MV_ACC 1 // full-pel mv accuracy for depth maps 162 179 #define VIDYO_VPS_INTEGRATION 1 180 #define HHI_DEPTH_INTRA_SEARCH_RAU_C0160 1 // JCT3V-C0160 change 1: full Intra search in depth random access units 163 181 164 182 ///// ***** VSP ********* … … 237 255 #if RWTH_SDC_DLT_B0036 238 256 #define Log2( n ) ( log((double)n) / log(2.0) ) 257 #define HS_REFERENCE_SUBSAMPLE_C0154 1 239 258 #endif 240 259 -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecCAVLC.cpp
r280 r287 1934 1934 { 1935 1935 UInt uiCodeTmp = 0; 1936 if ( rpcSlice->getSPS()->getViewId() && !rpcSlice->getSPS()->isDepth() ) 1936 if ( rpcSlice->getSPS()->getViewId() 1937 #if !LGE_ILLUCOMP_DEPTH_C0046 1938 && !rpcSlice->getSPS()->isDepth() 1939 #endif 1940 ) 1937 1941 { 1938 1942 READ_FLAG (uiCodeTmp, "applying IC flag"); -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecCu.cpp
r280 r287 375 375 pcCU->setHeight( uiAbsPartIdx + ui, g_uiMaxCUHeight>>uhNewDepth ); 376 376 } 377 #if LGE_ILLUCOMP_DEPTH_C0046 378 m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth ); 379 #endif 377 380 } 378 381 else … … 473 476 474 477 #if LGE_ILLUCOMP_B0045 478 #if LGE_ILLUCOMP_DEPTH_C0046 && HHI_MPI 479 if( pcCU->getTextureModeDepth( uiAbsPartIdx ) != uiDepth ) 480 { 481 #endif 475 482 m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth ); 476 483 #endif … … 480 487 { 481 488 m_pcEntropyDecoder->decodeResPredFlag ( pcCU, uiAbsPartIdx, uiDepth, m_ppcCU[uiDepth], 0 ); 489 } 490 #endif 491 #if LGE_ILLUCOMP_DEPTH_C0046 && HHI_MPI 482 492 } 483 493 #endif … … 505 515 pcCU->setHeight( uiAbsPartIdx + ui, g_uiMaxCUHeight>>uhNewDepth ); 506 516 } 507 517 #if LGE_ILLUCOMP_DEPTH_C0046 518 m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth ); 519 #endif 508 520 if( ( ( uiDepth < pcCU->getDepth( uiAbsPartIdx ) ) && ( uiDepth < g_uiMaxCUDepth - g_uiAddCUDepth ) ) || bBoundary ) 509 521 { … … 1418 1430 Int iSumPix[2]; 1419 1431 memset(iSumPix, 0, sizeof(Int)*2); 1420 1432 #if HS_REFERENCE_SUBSAMPLE_C0154 1433 Int subSamplePix; 1434 if ( uiSize == 64 || uiSize == 32 ) 1435 { 1436 subSamplePix = 2; 1437 } 1438 else 1439 { 1440 subSamplePix = 1; 1441 } 1442 for (Int y=0; y<uiSize; y+=subSamplePix) 1443 { 1444 for (Int x=0; x<uiSize; x+=subSamplePix) 1445 { 1446 UChar ucSegment = pMask?(UChar)pMask[x]:0; 1447 assert( ucSegment < uiNumSegments ); 1448 1449 iSumDepth[ucSegment] += pOrig[x]; 1450 iSumPix[ucSegment] += 1; 1451 } 1452 pOrig += uiStride*subSamplePix; 1453 pMask += uiMaskStride*subSamplePix; 1454 } 1455 #else 1421 1456 for (Int y=0; y<uiSize; y++) 1422 1457 { … … 1433 1468 pMask += uiMaskStride; 1434 1469 } 1435 1470 #endif 1436 1471 // compute mean for each segment 1437 1472 for( UChar ucSeg = 0; ucSeg < uiNumSegments; ucSeg++ ) -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecEntropy.cpp
r280 r287 72 72 pcCU->setICFlagSubParts( false , uiAbsPartIdx, 0, uiDepth ); 73 73 74 if (pcCU->isIntra(uiAbsPartIdx) || (pcCU->getSlice()->getViewId() == 0) || pcCU->getSlice()->getSPS()->isDepth()) 74 if (pcCU->isIntra(uiAbsPartIdx) || (pcCU->getSlice()->getViewId() == 0) 75 #if !LGE_ILLUCOMP_DEPTH_C0046 76 || pcCU->getSlice()->getSPS()->isDepth() 77 #endif 78 ) 75 79 { 76 80 return; … … 80 84 return; 81 85 86 #if LGE_ILLUCOMP_DEPTH_C0046 87 if(pcCU->isICFlagRequired(uiAbsPartIdx, uiDepth)) //This modification is not needed after integrating JCT3V-C0137 88 #else 82 89 if(pcCU->isICFlagRequired(uiAbsPartIdx)) 90 #endif 83 91 m_pcEntropyDecoderIf->parseICFlag( pcCU, uiAbsPartIdx, uiDepth ); 84 92 } -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecSbac.cpp
r189 r287 762 762 Bool bIntraSliceDetect = (pcCU->getSlice()->getSliceType() == I_SLICE); 763 763 764 #if HHI_QTLPC_RAU_OFF_C0160 765 Bool rapPic = (pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA); 766 if(bDepthMapDetect && !bIntraSliceDetect && !rapPic && sps->getUseQTLPC()) 767 #else 764 768 if(bDepthMapDetect && !bIntraSliceDetect && sps->getUseQTLPC()) 769 #endif 765 770 { 766 771 TComDataCU *pcTextureCU = pcTexture->getCU(pcCU->getAddr()); … … 804 809 Bool bIntraSliceDetect = (pcCU->getSlice()->getSliceType() == I_SLICE); 805 810 811 #if HHI_QTLPC_RAU_OFF_C0160 812 Bool rapPic = (pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA); 813 if(bDepthMapDetect && !bIntraSliceDetect && !rapPic && sps->getUseQTLPC()) 814 #else 806 815 if(bDepthMapDetect && !bIntraSliceDetect && sps->getUseQTLPC()) 816 #endif 807 817 { 808 818 TComDataCU *pcTextureCU = pcTexture->getCU(pcCU->getAddr()); … … 970 980 #if HHI_DMM_PRED_TEX 971 981 if( intraPredMode == DMM_WEDGE_PREDTEX_D_IDX ) { xParseWedgePredTexDeltaInfo ( pcCU, uiAbsPartIdx, uiDepth ); } 982 #if LGE_DMM3_SIMP_C0044 983 if( intraPredMode == DMM_WEDGE_PREDTEX_IDX ) { xParseWedgePredTexInfo ( pcCU, uiAbsPartIdx, uiDepth ); } 984 #endif 972 985 if( intraPredMode == DMM_CONTOUR_PREDTEX_D_IDX ) { xParseContourPredTexDeltaInfo( pcCU, uiAbsPartIdx, uiDepth ); } 973 986 #endif … … 2412 2425 #endif 2413 2426 #if HHI_DMM_PRED_TEX 2427 #if LGE_DMM3_SIMP_C0044 2428 Void TDecSbac::xParseWedgePredTexInfo( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 2429 { 2430 Int iIntraIdx = pcCU->getIntraSizeIdx(uiAbsPartIdx); 2431 Int iBits = g_aucWedgeTexPredBitsListIdx[iIntraIdx]; 2432 2433 UInt uiSymbol, uiTabIdx = 0; 2434 for ( Int i = 0; i < iBits; i++ ) 2435 { 2436 m_pcTDecBinIf->decodeBin( uiSymbol, m_cDmmDataSCModel.get(0, 0, 3) ); 2437 uiTabIdx += ( uiSymbol && i == 0 ) ? 1 : 0; 2438 uiTabIdx += ( uiSymbol && i == 1 ) ? 2 : 0; 2439 uiTabIdx += ( uiSymbol && i == 2 ) ? 4 : 0; 2440 uiTabIdx += ( uiSymbol && i == 3 ) ? 8 : 0; 2441 uiTabIdx += ( uiSymbol && i == 4 ) ? 16 : 0; 2442 uiTabIdx += ( uiSymbol && i == 5 ) ? 32 : 0; 2443 uiTabIdx += ( uiSymbol && i == 6 ) ? 64 : 0; 2444 uiTabIdx += ( uiSymbol && i == 7 ) ? 128 : 0; 2445 uiTabIdx += ( uiSymbol && i == 8 ) ? 256 : 0; 2446 uiTabIdx += ( uiSymbol && i == 9 ) ? 512 : 0; 2447 uiTabIdx += ( uiSymbol && i == 10 ) ? 1024 : 0; 2448 } 2449 2450 pcCU->setWedgePredTexIntraTabIdxSubParts( uiTabIdx, uiAbsPartIdx, uiDepth ); 2451 } 2452 #endif 2453 2414 2454 Void TDecSbac::xParseWedgePredTexDeltaInfo( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 2415 2455 { 2456 #if LGE_DMM3_SIMP_C0044 2457 xParseWedgePredTexInfo( pcCU, uiAbsPartIdx, uiDepth ); 2458 #endif 2416 2459 UInt uiDC1, uiDC2; 2417 2460 xReadExGolombLevel( uiDC1, m_cDmmDataSCModel.get(0, 0, 1) ); -
branches/HTM-5.1-dev0/source/Lib/TLibDecoder/TDecSbac.h
r280 r287 152 152 #endif 153 153 #if HHI_DMM_PRED_TEX 154 #if LGE_DMM3_SIMP_C0044 155 Void xParseWedgePredTexInfo ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 156 #endif 154 157 Void xParseWedgePredTexDeltaInfo ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 155 158 Void xParseContourPredTexDeltaInfo( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCavlc.cpp
r280 r287 869 869 if (address==0) 870 870 { 871 if( pcSlice->getSPS()->getViewId() && !pcSlice->getIsDepth() ) 871 if( pcSlice->getSPS()->getViewId() 872 #if !LGE_ILLUCOMP_DEPTH_C0046 873 && !pcSlice->getIsDepth() 874 #endif 875 ) 872 876 { 873 877 WRITE_FLAG( pcSlice->getApplyIC() ? 1 : 0, "applying IC flag" ); -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncCu.cpp
r280 r287 458 458 Bool bIntraSliceDetect = (rpcBestCU->getSlice()->getSliceType() == I_SLICE); 459 459 460 #if HHI_QTLPC_RAU_OFF_C0160 461 Bool rapPic = (rpcBestCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR || rpcBestCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA); 462 #endif 463 460 464 Bool bTry2NxN = true; 461 465 Bool bTryNx2N = true; … … 494 498 495 499 #if LGE_ILLUCOMP_B0045 496 Bool bICEnabled = (!rpcTempCU->getSlice()->getIsDepth() && rpcTempCU->getSlice()->getViewId()); 500 Bool bICEnabled = ( 501 #if !LGE_ILLUCOMP_DEPTH_C0046 502 !rpcTempCU->getSlice()->getIsDepth() && 503 #endif 504 rpcTempCU->getSlice()->getViewId()); 497 505 498 506 bICEnabled = bICEnabled && rpcTempCU->getSlice()->getApplyIC(); … … 612 620 #if OL_QTLIMIT_PREDCODING_B0068 613 621 //logic for setting bTrySplit using the partition information that is stored of the texture colocated CU 622 623 #if HHI_QTLPC_RAU_OFF_C0160 624 if(depthMapDetect && !bIntraSliceDetect && !rapPic && sps->getUseQTLPC()) 625 #else 614 626 if(depthMapDetect && !bIntraSliceDetect && sps->getUseQTLPC()) 627 #endif 615 628 { 616 629 TComDataCU* pcTextureCU = pcTexture->getCU( rpcBestCU->getAddr() ); //Corresponding texture LCU … … 699 712 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 700 713 #endif 714 #if FIX_LGE_ILLUCOMP_B0045 715 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 716 #endif 701 717 #if HHI_INTERVIEW_SKIP 702 718 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_2Nx2N, bFullyRenderedSec ); … … 724 740 725 741 #if OL_QTLIMIT_PREDCODING_B0068 742 743 #if HHI_QTLPC_RAU_OFF_C0160 744 if(depthMapDetect && !bIntraSliceDetect && !rapPic && sps->getUseQTLPC()) 745 #else 726 746 if(depthMapDetect && !bIntraSliceDetect && sps->getUseQTLPC()) 747 #endif 727 748 { 728 749 bTrySplitDQP = bTrySplit; … … 836 857 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 837 858 #endif 859 #if FIX_LGE_ILLUCOMP_B0045 860 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 861 #endif 838 862 #if HHI_INTERVIEW_SKIP 839 863 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_Nx2N, bFullyRenderedSec ); … … 860 884 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 861 885 #endif 886 #if FIX_LGE_ILLUCOMP_B0045 887 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 888 #endif 862 889 #if HHI_INTERVIEW_SKIP 863 890 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_2NxN, bFullyRenderedSec ); … … 903 930 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 904 931 #endif 932 #if FIX_LGE_ILLUCOMP_B0045 933 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 934 #endif 905 935 #if HHI_INTERVIEW_SKIP 906 936 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_2NxnU, bFullyRenderedSec ); … … 919 949 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 920 950 #endif 951 #if FIX_LGE_ILLUCOMP_B0045 952 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 953 #endif 921 954 #if HHI_INTERVIEW_SKIP 922 955 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_2NxnD, bFullyRenderedSec ); … … 946 979 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 947 980 #endif 981 #if FIX_LGE_ILLUCOMP_B0045 982 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 983 #endif 948 984 #if HHI_INTERVIEW_SKIP 949 985 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_2NxnU, bFullyRenderedSec, true ); … … 962 998 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 963 999 #endif 1000 #if FIX_LGE_ILLUCOMP_B0045 1001 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 1002 #endif 964 1003 #if HHI_INTERVIEW_SKIP 965 1004 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_2NxnD, bFullyRenderedSec, true ); … … 991 1030 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 992 1031 #endif 1032 #if FIX_LGE_ILLUCOMP_B0045 1033 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 1034 #endif 993 1035 #if HHI_INTERVIEW_SKIP 994 1036 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_nLx2N, bFullyRenderedSec ); … … 1007 1049 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 1008 1050 #endif 1051 #if FIX_LGE_ILLUCOMP_B0045 1052 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 1053 #endif 1009 1054 #if HHI_INTERVIEW_SKIP 1010 1055 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_nRx2N, bFullyRenderedSec ); … … 1029 1074 #if HHI_INTER_VIEW_RESIDUAL_PRED 1030 1075 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 1076 #endif 1077 #if FIX_LGE_ILLUCOMP_B0045 1078 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 1031 1079 #endif 1032 1080 #if HHI_INTERVIEW_SKIP … … 1046 1094 rpcTempCU->setResPredIndicator( bResPredAvailable, bResPredFlag ); 1047 1095 #endif 1096 #if FIX_LGE_ILLUCOMP_B0045 1097 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 1098 #endif 1048 1099 #if HHI_INTERVIEW_SKIP 1049 1100 xCheckRDCostInter( rpcBestCU, rpcTempCU, SIZE_nRx2N, bFullyRenderedSec, true ); … … 1113 1164 1114 1165 // do normal intra modes 1115 if ( !bEarlySkip ) 1166 if ( !bEarlySkip 1167 #if HHI_DEPTH_INTRA_SEARCH_RAU_C0160 1168 || ((rpcBestCU->getSlice()->getIsDepth() == true) && (rpcBestCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR || rpcBestCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA)) 1169 #endif 1170 ) 1116 1171 { 1117 1172 // speedup for inter frames … … 1120 1175 rpcBestCU->getCbf( 0, TEXT_LUMA ) != 0 || 1121 1176 rpcBestCU->getCbf( 0, TEXT_CHROMA_U ) != 0 || 1122 rpcBestCU->getCbf( 0, TEXT_CHROMA_V ) != 0 ) && !bFullyRenderedSec ) // avoid very complex intra if it is unlikely 1177 rpcBestCU->getCbf( 0, TEXT_CHROMA_V ) != 0 1178 #if HHI_DEPTH_INTRA_SEARCH_RAU_C0160 1179 || ((rpcBestCU->getSlice()->getIsDepth() == true) && (rpcBestCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR || rpcBestCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA)) 1180 #endif 1181 ) && !bFullyRenderedSec ) // avoid very complex intra if it is unlikely 1123 1182 #else 1124 1183 if( rpcBestCU->getSlice()->getSliceType() == I_SLICE || 1125 1184 rpcBestCU->getCbf( 0, TEXT_LUMA ) != 0 || 1126 1185 rpcBestCU->getCbf( 0, TEXT_CHROMA_U ) != 0 || 1127 rpcBestCU->getCbf( 0, TEXT_CHROMA_V ) != 0 ) // avoid very complex intra if it is unlikely 1186 rpcBestCU->getCbf( 0, TEXT_CHROMA_V ) != 0 1187 #if HHI_DEPTH_INTRA_SEARCH_RAU_C0160 1188 || ((rpcBestCU->getSlice()->getIsDepth() == true) && (rpcBestCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR || rpcBestCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA)) 1189 #endif 1190 ) // avoid very complex intra if it is unlikely 1128 1191 #endif 1129 1192 { … … 1178 1241 if( rpcBestCU->getSlice()->getSPS()->getUseMVI() && rpcBestCU->getSlice()->getSliceType() != I_SLICE ) 1179 1242 { 1243 #if LGE_ILLUCOMP_DEPTH_C0046 1244 for(UInt uiICId = 0; uiICId < (bICEnabled ? 2 : 1); uiICId++) 1245 { 1246 Bool bICFlag = (uiICId ? true : false); 1247 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 1248 #endif 1180 1249 xCheckRDCostMvInheritance( rpcBestCU, rpcTempCU, uiDepth, false, false ); 1181 1250 rpcTempCU->initEstData( uiDepth, iQP ); 1251 #if FIX_ILLUCOMP_DEPTH 1252 rpcTempCU->setICFlagSubParts(bICFlag, 0, 0, uiDepth); 1253 #endif 1182 1254 xCheckRDCostMvInheritance( rpcBestCU, rpcTempCU, uiDepth, true, false ); 1183 1255 rpcTempCU->initEstData( uiDepth, iQP ); 1256 #if LGE_ILLUCOMP_DEPTH_C0046 1257 } 1258 #endif 1184 1259 } 1185 1260 #endif … … 1738 1813 { 1739 1814 m_pcEntropyCoder->encodeMergeIndex( pcCU, uiAbsPartIdx, 0 ); 1815 #if LGE_ILLUCOMP_DEPTH_C0046 1816 m_pcEntropyCoder->encodeICFlag ( pcCU, uiAbsPartIdx, false, uiDepth ); 1817 #endif 1740 1818 finishCU(pcCU,uiAbsPartIdx,uiDepth); 1741 1819 xRestoreDepthWidthHeight( pcCU ); … … 1749 1827 // prediction Info ( Intra : direction mode, Inter : Mv, reference idx ) 1750 1828 m_pcEntropyCoder->encodePredInfo( pcCU, uiAbsPartIdx ); 1829 #if LGE_ILLUCOMP_DEPTH_C0046 1830 m_pcEntropyCoder->encodeICFlag ( pcCU, uiAbsPartIdx, false, uiDepth ); 1831 #endif 1751 1832 xRestoreDepthWidthHeight( pcCU ); 1752 1833 } … … 1797 1878 m_pcEntropyCoder->encodeMergeIndex( pcCU, uiAbsPartIdx, 0 ); 1798 1879 #if LGE_ILLUCOMP_B0045 1799 m_pcEntropyCoder->encodeICFlag ( pcCU, uiAbsPartIdx ); 1880 m_pcEntropyCoder->encodeICFlag ( pcCU, uiAbsPartIdx 1881 #if LGE_ILLUCOMP_DEPTH_C0046 1882 , false, uiDepth 1883 #endif 1884 ); 1800 1885 #endif 1801 1886 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 … … 1828 1913 m_pcEntropyCoder->encodePredInfo( pcCU, uiAbsPartIdx ); 1829 1914 #if LGE_ILLUCOMP_B0045 1830 m_pcEntropyCoder->encodeICFlag ( pcCU, uiAbsPartIdx ); 1915 m_pcEntropyCoder->encodeICFlag ( pcCU, uiAbsPartIdx 1916 #if LGE_ILLUCOMP_DEPTH_C0046 1917 ,false, uiDepth 1918 #endif 1919 ); 1831 1920 #endif 1832 1921 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 … … 2943 3032 m_pcEntropyCoder->encodeMergeIndex( pcCU, 0, 0, true ); 2944 3033 #if LGE_ILLUCOMP_B0045 2945 m_pcEntropyCoder->encodeICFlag( pcCU, 0, true ); 3034 m_pcEntropyCoder->encodeICFlag( pcCU, 0, true 3035 #if LGE_ILLUCOMP_DEPTH_C0046 3036 , uhDepth 3037 #endif 3038 ); 2946 3039 #endif 2947 3040 } … … 2953 3046 m_pcEntropyCoder->encodePredInfo( pcCU, 0, true ); 2954 3047 #if LGE_ILLUCOMP_B0045 2955 m_pcEntropyCoder->encodeICFlag( pcCU, 0, true ); 3048 m_pcEntropyCoder->encodeICFlag( pcCU, 0, true 3049 #if LGE_ILLUCOMP_DEPTH_C0046 3050 , uhDepth 3051 #endif 3052 ); 2956 3053 #endif 2957 3054 } -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncEntropy.cpp
r280 r287 170 170 171 171 #if LGE_ILLUCOMP_B0045 172 Void TEncEntropy::encodeICFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD ) 173 { 174 if (pcCU->isIntra(uiAbsPartIdx) || (pcCU->getSlice()->getViewId() == 0) || pcCU->getSlice()->getSPS()->isDepth()) 172 Void TEncEntropy::encodeICFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD 173 #if LGE_ILLUCOMP_DEPTH_C0046 174 , UInt uiDepth 175 #endif 176 ) 177 { 178 if (pcCU->isIntra(uiAbsPartIdx) || (pcCU->getSlice()->getViewId() == 0) 179 #if !LGE_ILLUCOMP_DEPTH_C0046 180 || pcCU->getSlice()->getSPS()->isDepth() 181 #endif 182 ) 175 183 { 176 184 return; … … 185 193 } 186 194 187 if(pcCU->isICFlagRequired(uiAbsPartIdx)) 195 if(pcCU->isICFlagRequired(uiAbsPartIdx 196 #if LGE_ILLUCOMP_DEPTH_C0046 197 , uiDepth //This modification is not needed after integrating JCT3V-C0137 198 #endif 199 )) 188 200 m_pcEntropyCoderIf->codeICFlag( pcCU, uiAbsPartIdx ); 189 201 } -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncEntropy.h
r280 r287 260 260 Void encodeSplitFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, Bool bRD = false ); 261 261 #if LGE_ILLUCOMP_B0045 262 Void encodeICFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD = false ); 262 Void encodeICFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD = false 263 #if LGE_ILLUCOMP_DEPTH_C0046 264 , UInt uiDepth = 0 265 #endif 266 ); 263 267 #endif 264 268 Void encodeSkipFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD = false ); -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSbac.cpp
r280 r287 625 625 Bool bIntraSliceDetect = (pcCU->getSlice()->getSliceType() == I_SLICE); 626 626 627 #if HHI_QTLPC_RAU_OFF_C0160 628 Bool rapPic = (pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA); 629 if(bDepthMapDetect && !bIntraSliceDetect && !rapPic && sps->getUseQTLPC() && pcCU->getPic()->getReduceBitsFlag()) 630 #else 627 631 if(bDepthMapDetect && !bIntraSliceDetect && sps->getUseQTLPC() && pcCU->getPic()->getReduceBitsFlag()) 632 #endif 628 633 { 629 634 TComDataCU *pcTextureCU = pcTexture->getCU(pcCU->getAddr()); … … 924 929 Bool bIntraSliceDetect = (pcCU->getSlice()->getSliceType() == I_SLICE); 925 930 931 #if HHI_QTLPC_RAU_OFF_C0160 932 Bool rapPic = (pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA); 933 if(bDepthMapDetect && !bIntraSliceDetect && !rapPic && sps->getUseQTLPC() && pcCU->getPic()->getReduceBitsFlag()) 934 #else 926 935 if(bDepthMapDetect && !bIntraSliceDetect && sps->getUseQTLPC() && pcCU->getPic()->getReduceBitsFlag()) 936 #endif 927 937 { 928 938 TComDataCU *pcTextureCU = pcTexture->getCU(pcCU->getAddr()); … … 1086 1096 1087 1097 if( uiDir == DMM_WEDGE_PREDTEX_D_IDX ) { xCodeWedgePredTexDeltaInfo ( pcCU, uiAbsPartIdx ); } 1098 #if LGE_DMM3_SIMP_C0044 1099 if( uiDir == DMM_WEDGE_PREDTEX_IDX ) { xCodeWedgePredTexInfo ( pcCU, uiAbsPartIdx ); } 1100 #endif 1088 1101 if( uiDir == DMM_CONTOUR_PREDTEX_D_IDX ) { xCodeContourPredTexDeltaInfo( pcCU, uiAbsPartIdx ); } 1089 1102 #endif … … 2673 2686 #endif 2674 2687 #if HHI_DMM_PRED_TEX 2688 #if LGE_DMM3_SIMP_C0044 2689 Void TEncSbac::xCodeWedgePredTexInfo( TComDataCU* pcCU, UInt uiAbsPartIdx ) 2690 { 2691 Int iIntraIdx = pcCU->getIntraSizeIdx(uiAbsPartIdx); 2692 Int iBits = g_aucWedgeTexPredBitsListIdx[iIntraIdx]; 2693 2694 UInt uiTabIdx = pcCU->getWedgePredTexIntraTabIdx( uiAbsPartIdx ); 2695 2696 for ( Int i = 0; i < iBits; i++ ) 2697 { 2698 m_pcBinIf->encodeBin( ( uiTabIdx >> i ) & 1, m_cDmmDataSCModel.get(0, 0, 3) ); 2699 } 2700 } 2701 #endif 2702 2675 2703 Void TEncSbac::xCodeWedgePredTexDeltaInfo( TComDataCU* pcCU, UInt uiAbsPartIdx ) 2676 2704 { 2705 #if LGE_DMM3_SIMP_C0044 2706 xCodeWedgePredTexInfo( pcCU, uiAbsPartIdx ); 2707 #endif 2677 2708 Int iDeltaDC1 = pcCU->getWedgePredTexDeltaDC1( uiAbsPartIdx ); 2678 2709 Int iDeltaDC2 = pcCU->getWedgePredTexDeltaDC2( uiAbsPartIdx ); -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSbac.h
r280 r287 178 178 #endif 179 179 #if HHI_DMM_PRED_TEX 180 #if LGE_DMM3_SIMP_C0044 181 Void xCodeWedgePredTexInfo ( TComDataCU* pcCU, UInt uiAbsPartIdx ); 182 #endif 180 183 Void xCodeWedgePredTexDeltaInfo ( TComDataCU* pcCU, UInt uiAbsPartIdx ); 181 184 Void xCodeContourPredTexDeltaInfo( TComDataCU* pcCU, UInt uiAbsPartIdx ); -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSearch.cpp
r280 r287 2253 2253 Int iTexDeltaDC1 = 0; 2254 2254 Int iTexDeltaDC2 = 0; 2255 #if LGE_DMM3_SIMP_C0044 2256 UInt uiTexIntraIdx = 0; 2257 findWedgeTexMinDist( pcCU, uiPartOffset, piOrg, piPred, uiStride, uiWidth, uiHeight, uiTexTabIdx, iTexDeltaDC1, iTexDeltaDC2, bAboveAvail, bLeftAvail, uiTexIntraIdx); 2258 pcCU->setWedgePredTexIntraTabIdxSubParts( uiTexIntraIdx, uiPartOffset, uiDepth + uiInitTrDepth ); 2259 #else 2255 2260 findWedgeTexMinDist( pcCU, uiPartOffset, piOrg, piPred, uiStride, uiWidth, uiHeight, uiTexTabIdx, iTexDeltaDC1, iTexDeltaDC2, bAboveAvail, bLeftAvail ); 2261 #endif 2256 2262 pcCU->setWedgePredTexTabIdxSubParts ( uiTexTabIdx, uiPartOffset, uiDepth + uiInitTrDepth ); 2257 2263 pcCU->setWedgePredTexDeltaDC1SubParts( iTexDeltaDC1, uiPartOffset, uiDepth + uiInitTrDepth ); … … 2345 2351 for( UInt uiSDC=0; uiSDC<=uiUseSDC; uiSDC++ ) 2346 2352 { 2353 #if FIX_SDC_ENC_C0143 2354 for( UInt uiRes = 0; uiRes<=uiSDC; uiRes++ ) 2355 #else 2347 2356 for( UInt uiRes = 0; uiRes<=uiUseSDC; uiRes++ ) 2357 #endif 2348 2358 { 2349 2359 #endif … … 4926 4936 m_pcEntropyCoder->encodeMergeIndex( pcCU, 0, 0, true ); 4927 4937 #if LGE_ILLUCOMP_B0045 4928 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true); 4938 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true 4939 #if FIX_ILLUCOMP_DEPTH 4940 , pcCU->getDepth( 0 ) 4941 #endif 4942 ); 4929 4943 #endif 4930 4944 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 … … 6309 6323 m_pcEntropyCoder->encodeMergeIndex(pcCU, 0, 0, true); 6310 6324 #if LGE_ILLUCOMP_B0045 6311 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true); 6325 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true 6326 #if FIX_ILLUCOMP_DEPTH 6327 , pcCU->getDepth( 0 ) 6328 #endif 6329 ); 6312 6330 #endif 6313 6331 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 … … 6332 6350 m_pcEntropyCoder->encodePredInfo( pcCU, 0, true ); 6333 6351 #if LGE_ILLUCOMP_B0045 6334 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true); 6352 m_pcEntropyCoder->encodeICFlag(pcCU, 0, true 6353 #if FIX_ILLUCOMP_DEPTH 6354 , pcCU->getDepth( 0 ) 6355 #endif 6356 ); 6335 6357 #endif 6336 6358 #if HHI_INTER_VIEW_RESIDUAL_PRED && !MTK_MDIVRP_C0138 … … 6671 6693 Int iFullDeltaDC2 = riDeltaDC2; 6672 6694 6695 #if HHI_DMM_DELTADC_Q1_C0034 6696 #else 6673 6697 xDeltaDCQuantScaleDown( pcCU, iFullDeltaDC1 ); 6674 6698 xDeltaDCQuantScaleDown( pcCU, iFullDeltaDC2 ); 6699 #endif 6675 6700 6676 6701 Dist uiBestDist = RDO_DIST_MAX; … … 6685 6710 uiDeltaDC2Max += (uiDeltaDC2Max>>1); 6686 6711 6712 #if HHI_DMM_DELTADC_Q1_C0034 6713 // limit search range to [0, IBDI_MAX] 6714 if( iFullDeltaDC1 < 0 && uiDeltaDC1Max > abs(iPredDC1) ) { uiDeltaDC1Max = abs(iPredDC1); } 6715 if( iFullDeltaDC1 >= 0 && uiDeltaDC1Max > g_uiIBDI_MAX - abs(iPredDC1) ) { uiDeltaDC1Max = g_uiIBDI_MAX - abs(iPredDC1); } 6716 6717 if( iFullDeltaDC2 < 0 && uiDeltaDC2Max > abs(iPredDC2) ) { uiDeltaDC2Max = abs(iPredDC2); } 6718 if( iFullDeltaDC2 >= 0 && uiDeltaDC2Max > g_uiIBDI_MAX - abs(iPredDC2) ) { uiDeltaDC2Max = g_uiIBDI_MAX - abs(iPredDC2); } 6719 6720 // init dist with original DCs 6721 assignWedgeDCs2Pred( pcWedgelet, piPredic, uiStride, iDC1, iDC2 ); 6722 6723 Dist uiOrgDist = RDO_DIST_MAX; 6724 #if SAIT_VSO_EST_A0033 6725 if ( m_pcRdCost->getUseEstimatedVSD() ) 6726 { 6727 TComPicYuv* pcVirRec = m_pcRdCost->getVideoRecPicYuv(); 6728 TComPicYuv* pcVirOrg = m_pcRdCost->getDepthPicYuv(); 6729 uiOrgDist = m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, pcVirRec->getLumaAddr(pcCU->getAddr(),pcCU->getZorderIdxInCU()), pcVirOrg->getLumaAddr(pcCU->getAddr(),pcCU->getZorderIdxInCU()), pcVirRec->getStride(), uiWidth, uiHeight ); 6730 #if LGE_WVSO_A0119 6731 if ( m_pcRdCost->getUseWVSO() ) 6732 { 6733 Int iDWeight = m_pcRdCost->getDWeight() * m_pcRdCost->getDWeight(); 6734 Int iVSDWeight = m_pcRdCost->getVSDWeight() * m_pcRdCost->getVSDWeight(); 6735 Dist iD = (Dist) m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, DF_SAD ); 6736 uiOrgDist = (iDWeight * iD + iVSDWeight * (Dist) uiOrgDist) / ( iDWeight + iVSDWeight); 6737 } 6738 #endif // LGE_WVSO_A0119 6739 } 6740 else 6741 #endif // SAIT_VSO_EST_A0033 6742 { 6743 uiOrgDist = m_pcRdCost->getDistVS( pcCU, 0, piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, 0 ); 6744 #if LGE_WVSO_A0119 6745 if ( m_pcRdCost->getUseWVSO() ) 6746 { 6747 Int iDWeight = m_pcRdCost->getDWeight() * m_pcRdCost->getDWeight(); 6748 Int iVSOWeight = m_pcRdCost->getVSOWeight() * m_pcRdCost->getVSOWeight(); 6749 Dist iD = (Dist) m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, DF_SAD ); 6750 uiOrgDist = (iDWeight * iD + iVSOWeight * (Dist) uiOrgDist) / ( iDWeight + iVSOWeight); 6751 } 6752 #endif // LGE_WVSO_A0119 6753 } 6754 uiBestDist = uiOrgDist; 6755 uiBestQStepDC1 = abs(iFullDeltaDC1); 6756 uiBestQStepDC2 = abs(iFullDeltaDC2); 6757 6758 // coarse search with step size 4 6759 for( UInt uiQStepDC1 = 0; uiQStepDC1 < uiDeltaDC1Max; uiQStepDC1 += 4 ) 6760 { 6761 Int iTestDC1 = Clip( iPredDC1 + ((Int)(uiQStepDC1) * (Int)(( iFullDeltaDC1 < 0 ) ? -1 : 1)) ); 6762 for( UInt uiQStepDC2 = 0; uiQStepDC2 < uiDeltaDC2Max; uiQStepDC2 += 4 ) 6763 { 6764 Int iTestDC2 = Clip( iPredDC2 + ((Int)(uiQStepDC2) * (Int)(( iFullDeltaDC2 < 0 ) ? -1 : 1)) ); 6765 6766 assignWedgeDCs2Pred( pcWedgelet, piPredic, uiStride, iTestDC1, iTestDC2 ); 6767 6768 Dist uiAct4Dist = RDO_DIST_MAX; 6769 #if SAIT_VSO_EST_A0033 6770 if ( m_pcRdCost->getUseEstimatedVSD() ) 6771 { 6772 TComPicYuv* pcVirRec = m_pcRdCost->getVideoRecPicYuv(); 6773 TComPicYuv* pcVirOrg = m_pcRdCost->getDepthPicYuv(); 6774 uiAct4Dist = m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, pcVirRec->getLumaAddr(pcCU->getAddr(),pcCU->getZorderIdxInCU()), pcVirOrg->getLumaAddr(pcCU->getAddr(),pcCU->getZorderIdxInCU()), pcVirRec->getStride(), uiWidth, uiHeight ); 6775 #if LGE_WVSO_A0119 6776 if ( m_pcRdCost->getUseWVSO() ) 6777 { 6778 Int iDWeight = m_pcRdCost->getDWeight() * m_pcRdCost->getDWeight(); 6779 Int iVSDWeight = m_pcRdCost->getVSDWeight() * m_pcRdCost->getVSDWeight(); 6780 Dist iD = (Dist) m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, DF_SAD ); 6781 uiAct4Dist = (iDWeight * iD + iVSDWeight * (Dist) uiAct4Dist) / ( iDWeight + iVSDWeight); 6782 } 6783 #endif // LGE_WVSO_A0119 6784 } 6785 else 6786 #endif // SAIT_VSO_EST_A0033 6787 { 6788 uiAct4Dist = m_pcRdCost->getDistVS( pcCU, 0, piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, 0 ); 6789 #if LGE_WVSO_A0119 6790 if ( m_pcRdCost->getUseWVSO() ) 6791 { 6792 Int iDWeight = m_pcRdCost->getDWeight() * m_pcRdCost->getDWeight(); 6793 Int iVSOWeight = m_pcRdCost->getVSOWeight() * m_pcRdCost->getVSOWeight(); 6794 Dist iD = (Dist) m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, DF_SAD ); 6795 uiAct4Dist = (iDWeight * iD + iVSOWeight * (Dist) uiAct4Dist) / ( iDWeight + iVSOWeight); 6796 } 6797 #endif // LGE_WVSO_A0119 6798 } 6799 6800 if( uiAct4Dist < uiBestDist || uiBestDist == RDO_DIST_MAX ) 6801 { 6802 uiBestDist = uiAct4Dist; 6803 uiBestQStepDC1 = uiQStepDC1; 6804 uiBestQStepDC2 = uiQStepDC2; 6805 } 6806 } 6807 } 6808 6809 // refinement +-3 6810 for( UInt uiQStepDC1 = (UInt)max(0, ((Int)uiBestQStepDC1-3)); uiQStepDC1 <= (uiBestQStepDC1+3); uiQStepDC1++ ) 6811 { 6812 Int iTestDC1 = Clip( iPredDC1 + ((Int)(uiQStepDC1) * (Int)(( iFullDeltaDC1 < 0 ) ? -1 : 1)) ); 6813 for( UInt uiQStepDC2 = (UInt)max(0, ((Int)uiBestQStepDC2-3)); uiQStepDC2 <= (uiBestQStepDC2+3); uiQStepDC2++ ) 6814 { 6815 Int iTestDC2 = Clip( iPredDC2 + ((Int)(uiQStepDC2) * (Int)(( iFullDeltaDC2 < 0 ) ? -1 : 1)) ); 6816 6817 assignWedgeDCs2Pred( pcWedgelet, piPredic, uiStride, iTestDC1, iTestDC2 ); 6818 6819 Dist uiActDist = RDO_DIST_MAX; 6820 #if SAIT_VSO_EST_A0033 6821 if ( m_pcRdCost->getUseEstimatedVSD() ) 6822 { 6823 TComPicYuv* pcVirRec = m_pcRdCost->getVideoRecPicYuv(); 6824 TComPicYuv* pcVirOrg = m_pcRdCost->getDepthPicYuv(); 6825 uiActDist = m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, pcVirRec->getLumaAddr(pcCU->getAddr(),pcCU->getZorderIdxInCU()), pcVirOrg->getLumaAddr(pcCU->getAddr(),pcCU->getZorderIdxInCU()), pcVirRec->getStride(), uiWidth, uiHeight ); 6826 #if LGE_WVSO_A0119 6827 if ( m_pcRdCost->getUseWVSO() ) 6828 { 6829 Int iDWeight = m_pcRdCost->getDWeight() * m_pcRdCost->getDWeight(); 6830 Int iVSDWeight = m_pcRdCost->getVSDWeight() * m_pcRdCost->getVSDWeight(); 6831 Dist iD = (Dist) m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, DF_SAD ); 6832 uiActDist = (iDWeight * iD + iVSDWeight * (Dist) uiActDist) / ( iDWeight + iVSDWeight); 6833 } 6834 #endif // LGE_WVSO_A0119 6835 } 6836 else 6837 #endif // SAIT_VSO_EST_A0033 6838 { 6839 uiActDist = m_pcRdCost->getDistVS( pcCU, 0, piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, 0 ); 6840 #if LGE_WVSO_A0119 6841 if ( m_pcRdCost->getUseWVSO() ) 6842 { 6843 Int iDWeight = m_pcRdCost->getDWeight() * m_pcRdCost->getDWeight(); 6844 Int iVSOWeight = m_pcRdCost->getVSOWeight() * m_pcRdCost->getVSOWeight(); 6845 Dist iD = (Dist) m_pcRdCost->getDistPart( piPredic, uiStride, piOrig, uiStride, uiWidth, uiHeight, false, DF_SAD ); 6846 uiActDist = (iDWeight * iD + iVSOWeight * (Dist) uiActDist) / ( iDWeight + iVSOWeight); 6847 } 6848 #endif // LGE_WVSO_A0119 6849 } 6850 6851 if( uiActDist < uiBestDist || uiBestDist == RDO_DIST_MAX ) 6852 { 6853 uiBestDist = uiActDist; 6854 uiBestQStepDC1 = uiQStepDC1; 6855 uiBestQStepDC2 = uiQStepDC2; 6856 } 6857 } 6858 } 6859 #else 6687 6860 for( UInt uiQStepDC1 = 1; uiQStepDC1 <= uiDeltaDC1Max; uiQStepDC1++ ) 6688 6861 { … … 6740 6913 } 6741 6914 } 6742 6915 #endif 6743 6916 iFullDeltaDC1 = (Int)(uiBestQStepDC1) * (Int)(( iFullDeltaDC1 < 0 ) ? -1 : 1); 6744 6917 iFullDeltaDC2 = (Int)(uiBestQStepDC2) * (Int)(( iFullDeltaDC2 < 0 ) ? -1 : 1); 6918 #if HHI_DMM_DELTADC_Q1_C0034 6919 #else 6745 6920 xDeltaDCQuantScaleUp( pcCU, iFullDeltaDC1 ); 6746 6921 xDeltaDCQuantScaleUp( pcCU, iFullDeltaDC2 ); 6922 #endif 6747 6923 riDeltaDC1 = iFullDeltaDC1; 6748 6924 riDeltaDC2 = iFullDeltaDC2; … … 6750 6926 #endif 6751 6927 6928 #if HHI_DMM_DELTADC_Q1_C0034 6929 #else 6752 6930 xDeltaDCQuantScaleDown( pcCU, riDeltaDC1 ); 6753 6931 xDeltaDCQuantScaleDown( pcCU, riDeltaDC2 ); 6932 #endif 6754 6933 } 6755 6934 #endif … … 7111 7290 Int& riDeltaDC2, 7112 7291 Bool bAboveAvail, 7113 Bool bLeftAvail ) 7292 Bool bLeftAvail 7293 #if LGE_DMM3_SIMP_C0044 7294 ,UInt& ruiIntraTabIdx 7295 #endif 7296 ) 7114 7297 { 7115 7298 assert( uiWidth >= DMM_WEDGEMODEL_MIN_SIZE && uiWidth <= DMM_WEDGEMODEL_MAX_SIZE ); 7116 7299 WedgeList* pacWedgeList = &g_aacWedgeLists[(g_aucConvertToBit[uiWidth])]; 7117 7300 7301 #if LGE_DMM3_SIMP_C0044 7302 ruiTabIdx = getBestWedgeFromTex( pcCU, uiAbsPtIdx, uiWidth, uiHeight, piOrig, uiStride, ruiIntraTabIdx ); 7303 #else 7118 7304 ruiTabIdx = getBestWedgeFromTex( pcCU, uiAbsPtIdx, uiWidth, uiHeight ); 7305 #endif 7119 7306 7120 7307 TComWedgelet* pcBestWedgelet = &(pacWedgeList->at(ruiTabIdx)); … … 8261 8448 Int iSumPix[2]; 8262 8449 memset(iSumPix, 0, sizeof(Int)*2); 8263 8450 #if HS_REFERENCE_SUBSAMPLE_C0154 8451 Int subSamplePix; 8452 if ( uiSize == 64 || uiSize == 32 ) 8453 { 8454 subSamplePix = 2; 8455 } 8456 else 8457 { 8458 subSamplePix = 1; 8459 } 8460 for (Int y=0; y<uiSize; y+=subSamplePix) 8461 { 8462 for (Int x=0; x<uiSize; x+=subSamplePix) 8463 { 8464 UChar ucSegment = pMask?(UChar)pMask[x]:0; 8465 assert( ucSegment < uiNumSegments ); 8466 8467 iSumDepth[ucSegment] += pOrig[x]; 8468 iSumPix[ucSegment] += 1; 8469 } 8470 8471 pOrig += uiStride*subSamplePix; 8472 pMask += uiMaskStride*subSamplePix; 8473 } 8474 #else 8264 8475 for (Int y=0; y<uiSize; y++) 8265 8476 { … … 8276 8487 pMask += uiMaskStride; 8277 8488 } 8278 8489 #endif 8279 8490 // compute mean for each segment 8280 8491 for( UChar ucSeg = 0; ucSeg < uiNumSegments; ucSeg++ ) -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSearch.h
r280 r287 435 435 Int& riDeltaDC2, 436 436 Bool bAboveAvail, 437 Bool bLeftAvail ); 437 Bool bLeftAvail 438 #if LGE_DMM3_SIMP_C0044 439 ,UInt& ruiIntraTabIdx 440 #endif 441 ); 438 442 Void findContourPredTex ( TComDataCU* pcCU, 439 443 UInt uiAbsPtIdx, -
branches/HTM-5.1-dev0/source/Lib/TLibEncoder/TEncSlice.cpp
r280 r287 776 776 777 777 #if LGE_ILLUCOMP_B0045 778 if (pcEncTop->getViewId() != 0 && !pcEncTop->isDepthCoder() && pcEncTop->getUseIC()) // DCP of ViewID 0 is not available 778 if (pcEncTop->getViewId() != 0 779 #if !LGE_ILLUCOMP_DEPTH_C0046 780 && !pcEncTop->isDepthCoder() 781 #endif 782 && pcEncTop->getUseIC()) // DCP of ViewID 0 is not available 779 783 { 780 784 pcSlice ->xSetApplyIC();
Note: See TracChangeset for help on using the changeset viewer.