Changeset 379 in 3DVCSoftware
- Timestamp:
- 6 May 2013, 05:34:34 (12 years ago)
- Location:
- branches/HTM-6.2-dev3-Qualcomm/source/Lib
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-6.2-dev3-Qualcomm/source/Lib/TLibCommon/TComPrediction.cpp
r342 r379 540 540 // Do prediction 541 541 { 542 #if QC_DC_PREDICTOR_D0183 543 Int iMean0, iMean1; 544 getPredDCs( pbRegion, iWidth, pSrc+srcStride+1, srcStride, iMean0, iMean1 ); 545 #else 542 546 //UInt uiSum0 = 0, uiSum1 = 0; 543 547 Int iSum0 = 0, iSum1 = 0; … … 578 582 iMean0 = iSum0 / iCount0; // TODO : integer op. 579 583 iMean1 = iSum1 / iCount1; 584 #endif 580 585 #if LGE_EDGE_INTRA_DELTA_DC 581 586 if( bDelta ) … … 2431 2436 } 2432 2437 2438 #if QC_DC_PREDICTOR_D0183 2439 Void TComPrediction::getPredDCs( Bool* pbPattern, Int iStride, Int* piMask, Int iMaskStride, Int& riPredDC1, Int& riPredDC2 ) 2440 { 2441 Int iDC1, iDC2; 2442 const Int iTR = ( iStride - 1 ) - iMaskStride; 2443 const Int iTM = ( ( iStride - 1 ) >> 1 ) - iMaskStride; 2444 const Int iLB = ( iStride - 1 ) * iMaskStride - 1; 2445 const Int iLM = ( ( iStride - 1 ) >> 1 ) * iMaskStride - 1; 2446 const UInt uiBitDepth = g_uiBitDepth + g_uiBitIncrement; 2447 2448 Bool bL = ( pbPattern[0] != pbPattern[(iStride-1)*iStride] ); 2449 Bool bT = ( pbPattern[0] != pbPattern[(iStride-1)] ); 2450 2451 if( bL == bT ) 2452 { 2453 iDC1 = bL ? ( piMask[iTR] + piMask[iLB] )>>1 : 1<<( uiBitDepth - 1 ); 2454 iDC2 = ( piMask[ -1] + piMask[-iMaskStride] )>>1; 2455 } 2456 else 2457 { 2458 iDC1 = bL ? piMask[iLB] : piMask[iTR]; 2459 iDC2 = bL ? piMask[iTM] : piMask[iLM]; 2460 } 2461 2462 riPredDC1 = pbPattern[0] ? iDC1 : iDC2; 2463 riPredDC2 = pbPattern[0] ? iDC2 : iDC1; 2464 } 2465 #else 2433 2466 Void TComPrediction::getWedgePredDCs( TComWedgelet* pcWedgelet, Int* piMask, Int iMaskStride, Int& riPredDC1, Int& riPredDC2, Bool bAbove, Bool bLeft ) 2434 2467 { … … 2508 2541 } 2509 2542 } 2543 #endif 2510 2544 2511 2545 Void TComPrediction::calcWedgeDCs( TComWedgelet* pcWedgelet, Pel* piOrig, UInt uiStride, Int& riDC1, Int& riDC2 ) … … 2875 2909 Int iMaskStride = ( iWidth<<1 ) + 1; 2876 2910 piMask += iMaskStride+1; 2911 #if QC_DC_PREDICTOR_D0183 2912 getPredDCs( pcWedgelet->getPattern(), pcWedgelet->getStride(), piMask, iMaskStride, iPredDC1, iPredDC2 ); 2913 #else 2877 2914 getWedgePredDCs( pcWedgelet, piMask, iMaskStride, iPredDC1, iPredDC2, bAbove, bLeft ); 2915 #endif 2878 2916 2879 2917 // assign wedge pred DCs to prediction … … 2904 2942 Int iMaskStride = ( iWidth<<1 ) + 1; 2905 2943 piMask += iMaskStride+1; 2944 #if QC_DC_PREDICTOR_D0183 2945 getPredDCs( pcContourWedge->getPattern(), pcContourWedge->getStride(), piMask, iMaskStride, iPredDC1, iPredDC2 ); 2946 #else 2906 2947 getWedgePredDCs( pcContourWedge, piMask, iMaskStride, iPredDC1, iPredDC2, bAbove, bLeft ); 2948 #endif 2907 2949 2908 2950 // assign wedge pred DCs to prediction … … 3089 3131 Int iMaskStride = ( iWidth<<1 ) + 1; 3090 3132 piMask += iMaskStride+1; 3133 #if QC_DC_PREDICTOR_D0183 3134 getPredDCs( pcWedgelet->getPattern(), pcWedgelet->getStride(), piMask, iMaskStride, iPredDC1, iPredDC2 ); 3135 #else 3091 3136 getWedgePredDCs( pcWedgelet, piMask, iMaskStride, iPredDC1, iPredDC2, bAbove, bLeft ); 3137 #endif 3092 3138 3093 3139 // assign wedge pred DCs to prediction … … 3134 3180 Int iMaskStride = ( iWidth<<1 ) + 1; 3135 3181 piMask += iMaskStride+1; 3182 #if QC_DC_PREDICTOR_D0183 3183 getPredDCs( pcWedgelet->getPattern(), pcWedgelet->getStride(), piMask, iMaskStride, iPredDC1, iPredDC2 ); 3184 #else 3136 3185 getWedgePredDCs( pcWedgelet, piMask, iMaskStride, iPredDC1, iPredDC2, bAbove, bLeft ); 3186 #endif 3137 3187 3138 3188 // assign wedge pred DCs to prediction -
branches/HTM-6.2-dev3-Qualcomm/source/Lib/TLibCommon/TComPrediction.h
r332 r379 191 191 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 192 192 Void predIntraLumaDMM ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiMode, Pel* piPred, UInt uiStride, Int iWidth, Int iHeight, Bool bAbove, Bool bLeft, Bool bEncoder ); 193 193 #if QC_DC_PREDICTOR_D0183 194 Void getPredDCs ( Bool* pbPattern, Int iPatternStride, Int* piMask, Int iMaskStride, Int& riPredDC1, Int& riPredDC2 ); 195 #else 194 196 Void getWedgePredDCs ( TComWedgelet* pcWedgelet, Int* piMask, Int iMaskStride, Int& riPredDC1, Int& riPredDC2, Bool bAbove, Bool bLeft ); 197 #endif 195 198 Void calcWedgeDCs ( TComWedgelet* pcWedgelet, Pel* piOrig, UInt uiStride, Int& riDC1, Int& riDC2 ); 196 199 Void assignWedgeDCs2Pred ( TComWedgelet* pcWedgelet, Pel* piPred, UInt uiStride, Int iDC1, Int iDC2 ); -
branches/HTM-6.2-dev3-Qualcomm/source/Lib/TLibCommon/TypeDef.h
r356 r379 63 63 #define LGE_EDGE_INTRA_A0070 1 // JCT3V-A0070 64 64 #define LGE_DMM3_SIMP_C0044 1 65 66 #define QC_DC_PREDICTOR_D0183 1 // JCT3V-D0183: Simplified DC predictor for depth intra modes 65 67 66 68 ///// ***** SDC ********* -
branches/HTM-6.2-dev3-Qualcomm/source/Lib/TLibEncoder/TEncSearch.cpp
r350 r379 6312 6312 Int iMaskStride = ( uiWidth<<1 ) + 1; 6313 6313 piMask += iMaskStride+1; 6314 #if QC_DC_PREDICTOR_D0183 6315 getPredDCs( pcWedgelet->getPattern(), pcWedgelet->getStride(), piMask, iMaskStride, iPredDC1, iPredDC2 ); 6316 #else 6314 6317 getWedgePredDCs( pcWedgelet, piMask, iMaskStride, iPredDC1, iPredDC2, bAboveAvail, bLeftAvail ); 6318 #endif 6315 6319 6316 6320 riDeltaDC1 = iDC1 - iPredDC1; … … 7877 7881 7878 7882 // PredDC Calculation 7883 #if QC_DC_PREDICTOR_D0183 7884 getPredDCs( pbRegion, uiWidth, piMask+iMaskStride+1, iMaskStride, iPredDC0, iPredDC1 ); 7885 #else 7879 7886 { 7880 7887 UInt uiSum0 = 0; … … 7916 7923 iPredDC1 = uiSum1 / uiCount1; 7917 7924 } 7925 #endif 7918 7926 7919 7927 iDeltaDC0 = iDC0 - iPredDC0;
Note: See TracChangeset for help on using the changeset viewer.