Ignore:
Timestamp:
20 Jan 2014, 04:34:18 (10 years ago)
Author:
qualcomm
Message:

integration of JCT3V-G0122 (generalize SDC to all depth intra modes) by Qualcomm.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-9.3-dev3-Qualcomm/source/Lib/TLibCommon/TComPrediction.cpp

    r773 r781  
    416416
    417417#if H_3D_DIM
    418 Void TComPrediction::predIntraLumaDepth( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiIntraMode, Pel* piPred, UInt uiStride, Int iWidth, Int iHeight, Bool bFastEnc )
     418Void TComPrediction::predIntraLumaDepth( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiIntraMode, Pel* piPred, UInt uiStride, Int iWidth, Int iHeight, Bool bFastEnc
     419#if QC_GENERIC_SDC_G0122
     420  , TComWedgelet* dmm4Segmentation
     421#endif
     422  )
    419423{
    420424  assert( iWidth == iHeight  );
     
    442446    case( DMM4_IDX ):
    443447      {
     448#if QC_GENERIC_SDC_G0122
     449        if( dmm4Segmentation == NULL )
     450        {
     451          dmmSegmentation = new TComWedgelet( iWidth, iHeight );
     452          xPredContourFromTex( pcCU, uiAbsPartIdx, iWidth, iHeight, dmmSegmentation );
     453        }
     454        else
     455        {
     456          xPredContourFromTex( pcCU, uiAbsPartIdx, iWidth, iHeight, dmm4Segmentation );
     457          dmmSegmentation = dmm4Segmentation;
     458        }
     459#else
    444460        dmmSegmentation = new TComWedgelet( iWidth, iHeight );
    445461        xPredContourFromTex( pcCU, uiAbsPartIdx, iWidth, iHeight, dmmSegmentation );
     462#endif
    446463      } break;
    447464    default: assert(0);
     
    494511
    495512#if H_3D_DIM_DMM
     513#if QC_GENERIC_SDC_G0122
     514  if( dimType == DMM4_IDX && dmm4Segmentation == NULL ) { dmmSegmentation->destroy(); delete dmmSegmentation; }
     515#else
    496516  if( dimType == DMM4_IDX ) { dmmSegmentation->destroy(); delete dmmSegmentation; }
     517#endif
    497518#endif
    498519}
     
    21842205  Int iSumPix[2];
    21852206  memset(iSumPix, 0, sizeof(Int)*2);
    2186  
     2207#if QC_GENERIC_SDC_G0122
     2208  for( Int i = 0; i < uiNumSegments; i++ )
     2209  {
     2210    rpSegMeans[i] = 0;
     2211  }
     2212#endif
    21872213  if (orgDC == false)
    21882214  {
     
    21992225      rpSegMeans[ucSegmentRB] = pOrig[uiStride * (uiSize-1) + (uiSize-1) ];
    22002226    }
     2227#if QC_GENERIC_SDC_G0122
     2228    else if( getDimType( uiIntraMode ) == DMM4_IDX )
     2229    {
     2230      Pel *ptmpOrig = pOrig;
     2231      Bool *ptmpMask = pMask, bBreak = false;
     2232      UChar ucSegment = ptmpMask? (UChar) ptmpMask[0] : 0;
     2233      UChar bFirstSeg = ucSegment;
     2234
     2235      rpSegMeans[ucSegment] = ptmpOrig[0];
     2236      for ( Int y = 0; y < uiSize; y++ )
     2237      {
     2238        for ( Int x = 0; x < uiSize; x++ )
     2239        {
     2240          ucSegment = ptmpMask[x];
     2241          assert( ucSegment < uiNumSegments );
     2242
     2243          if( bFirstSeg != ucSegment )
     2244          {
     2245            rpSegMeans[ucSegment] = ptmpOrig[x];
     2246            bBreak = true;
     2247            break;
     2248          }
     2249        }
     2250
     2251        if( bBreak )
     2252        {
     2253          break;
     2254        }
     2255
     2256        ptmpOrig  += uiStride;
     2257        ptmpMask  += uiMaskStride;
     2258      }
     2259    }
     2260    else
     2261#else
    22012262    else if (uiIntraMode == PLANAR_IDX)
     2263#endif
    22022264    {
    22032265      Pel* pLeftTop = pOrig;
Note: See TracChangeset for help on using the changeset viewer.