Changeset 1368 in SHVCSoftware for branches/SHM-dev/source/Lib/TLibEncoder


Ignore:
Timestamp:
22 Jul 2015, 04:43:32 (10 years ago)
Author:
seregin
Message:

port rev 4486

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-dev/source/Lib/TLibEncoder/TEncSearch.cpp

    r1363 r1368  
    11581158
    11591159  //===== init availability pattern =====
    1160   Bool  bAboveAvail = false;
    1161   Bool  bLeftAvail  = false;
    1162 
    11631160  DEBUG_STRING_NEW(sTemp)
    11641161
     
    11691166    const Bool bUseFilteredPredictions=TComPrediction::filteringIntraReferenceSamples(compID, uiChFinalMode, uiWidth, uiHeight, chFmt, sps.getSpsRangeExtension().getIntraSmoothingDisabledFlag());
    11701167
    1171     initIntraPatternChType( rTu, bAboveAvail, bLeftAvail, compID, bUseFilteredPredictions DEBUG_STRING_PASS_INTO(sDebug) );
     1168    initIntraPatternChType( rTu, compID, bUseFilteredPredictions DEBUG_STRING_PASS_INTO(sDebug) );
    11721169
    11731170    //===== get prediction signal =====
    1174     predIntraAng( compID, uiChFinalMode, piOrg, uiStride, piPred, uiStride, rTu, bAboveAvail, bLeftAvail, bUseFilteredPredictions );
     1171    predIntraAng( compID, uiChFinalMode, piOrg, uiStride, piPred, uiStride, rTu, bUseFilteredPredictions );
    11751172
    11761173    // save prediction
     
    14621459  checkTransformSkip           &= (!pcCU->getCUTransquantBypass(0));
    14631460
     1461  assert (rTu.ProcessComponentSection(COMPONENT_Y));
     1462  const UInt totalAdjustedDepthChan   = rTu.GetTransformDepthTotalAdj(COMPONENT_Y);
     1463
    14641464  if ( m_pcEncCfg->getUseTransformSkipFast() )
    14651465  {
     
    14931493        }
    14941494
    1495         if (rTu.ProcessComponentSection(COMPONENT_Y))
    1496         {
    1497           const UInt totalAdjustedDepthChan = rTu.GetTransformDepthTotalAdj(COMPONENT_Y);
    1498           pcCU->setTransformSkipSubParts ( modeId, COMPONENT_Y, uiAbsPartIdx, totalAdjustedDepthChan );
    1499 
    1500           xIntraCodingTUBlock( pcOrgYuv, pcPredYuv, pcResiYuv, resiLumaSingle, false, singleDistTmpLuma, COMPONENT_Y, rTu DEBUG_STRING_PASS_INTO(sModeString), default0Save1Load2 );
    1501         }
     1495
     1496        pcCU->setTransformSkipSubParts ( modeId, COMPONENT_Y, uiAbsPartIdx, totalAdjustedDepthChan );
     1497        xIntraCodingTUBlock( pcOrgYuv, pcPredYuv, pcResiYuv, resiLumaSingle, false, singleDistTmpLuma, COMPONENT_Y, rTu DEBUG_STRING_PASS_INTO(sModeString), default0Save1Load2 );
     1498
    15021499        singleCbfTmpLuma = pcCU->getCbf( uiAbsPartIdx, COMPONENT_Y, uiTrDepth );
    15031500
     
    15461543      }
    15471544
    1548       if (rTu.ProcessComponentSection(COMPONENT_Y))
    1549       {
    1550         const UInt totalAdjustedDepthChan   = rTu.GetTransformDepthTotalAdj(COMPONENT_Y);
    1551         pcCU ->setTransformSkipSubParts ( bestModeId[COMPONENT_Y], COMPONENT_Y, uiAbsPartIdx, totalAdjustedDepthChan );
    1552       }
     1545      pcCU ->setTransformSkipSubParts ( bestModeId[COMPONENT_Y], COMPONENT_Y, uiAbsPartIdx, totalAdjustedDepthChan );
    15531546
    15541547      if(bestModeId[COMPONENT_Y] == firstCheckId)
    15551548      {
    15561549        xLoadIntraResultQT(COMPONENT_Y, rTu );
    1557         if (rTu.ProcessComponentSection(COMPONENT_Y))
    1558         {
    1559           pcCU->setCbfSubParts  ( uiSingleCbfLuma << uiTrDepth, COMPONENT_Y, uiAbsPartIdx, rTu.GetTransformDepthTotalAdj(COMPONENT_Y) );
    1560         }
     1550        pcCU->setCbfSubParts  ( uiSingleCbfLuma << uiTrDepth, COMPONENT_Y, uiAbsPartIdx, rTu.GetTransformDepthTotalAdj(COMPONENT_Y) );
    15611551
    15621552        m_pcRDGoOnSbacCoder->load( m_pppcRDSbacCoder[ uiFullDepth ][ CI_TEMP_BEST ] );
     
    15721562      //----- code luma/chroma block with given intra prediction mode and store Cbf-----
    15731563      dSingleCost   = 0.0;
    1574       if (rTu.ProcessComponentSection(COMPONENT_Y))
    1575       {
    1576         const UInt totalAdjustedDepthChan   = rTu.GetTransformDepthTotalAdj(COMPONENT_Y);
    1577         pcCU ->setTransformSkipSubParts ( 0, COMPONENT_Y, uiAbsPartIdx, totalAdjustedDepthChan );
    1578       }
    1579 
     1564
     1565      pcCU ->setTransformSkipSubParts ( 0, COMPONENT_Y, uiAbsPartIdx, totalAdjustedDepthChan );
    15801566      xIntraCodingTUBlock( pcOrgYuv, pcPredYuv, pcResiYuv, resiLumaSingle, false, uiSingleDistLuma, COMPONENT_Y, rTu DEBUG_STRING_PASS_INTO(sDebug));
    15811567
     
    16891675    pcCU->setTrIdxSubParts( uiTrDepth, uiAbsPartIdx, uiFullDepth );
    16901676    const TComRectangle &tuRect=rTu.getRect(COMPONENT_Y);
    1691     const UInt totalAdjustedDepthChan   = rTu.GetTransformDepthTotalAdj(COMPONENT_Y);
    16921677    pcCU->setCbfSubParts  ( uiSingleCbfLuma << uiTrDepth, COMPONENT_Y, uiAbsPartIdx, totalAdjustedDepthChan );
    16931678    pcCU ->setTransformSkipSubParts  ( bestModeId[COMPONENT_Y], COMPONENT_Y, uiAbsPartIdx, totalAdjustedDepthChan );
     
    22432228  //{
    22442229    //===== init pattern for luma prediction =====
    2245     Bool bAboveAvail = false;
    2246     Bool bLeftAvail  = false;
    22472230    DEBUG_STRING_NEW(sTemp2)
    22482231
     
    22522235    Int numModesForFullRD = m_pcEncCfg->getFastUDIUseMPMEnabled()?g_aucIntraModeNumFast_UseMPM[ uiWidthBit ] : g_aucIntraModeNumFast_NotUseMPM[ uiWidthBit ];
    22532236
    2254     if (tuRecurseWithPU.ProcessComponentSection(COMPONENT_Y))
    2255     {
    2256       initIntraPatternChType( tuRecurseWithPU, bAboveAvail, bLeftAvail, COMPONENT_Y, true DEBUG_STRING_PASS_INTO(sTemp2) );
    2257     }
     2237    // this should always be true
     2238    assert (tuRecurseWithPU.ProcessComponentSection(COMPONENT_Y));
     2239    initIntraPatternChType( tuRecurseWithPU, COMPONENT_Y, true DEBUG_STRING_PASS_INTO(sTemp2) );
    22582240
    22592241    Bool doFastSearch = (numModesForFullRD != numModesAvailable);
     
    23192301        const Bool bUseFilter=TComPrediction::filteringIntraReferenceSamples(COMPONENT_Y, uiMode, puRect.width, puRect.height, chFmt, sps.getSpsRangeExtension().getIntraSmoothingDisabledFlag());
    23202302
    2321         predIntraAng( COMPONENT_Y, uiMode, piOrg, uiStride, piPred, uiStride, tuRecurseWithPU, bAboveAvail, bLeftAvail, bUseFilter, TComPrediction::UseDPCMForFirstPassIntraEstimation(tuRecurseWithPU, uiMode) );
     2303        predIntraAng( COMPONENT_Y, uiMode, piOrg, uiStride, piPred, uiStride, tuRecurseWithPU, bUseFilter, TComPrediction::UseDPCMForFirstPassIntraEstimation(tuRecurseWithPU, uiMode) );
    23222304
    23232305        // use hadamard transform here
Note: See TracChangeset for help on using the changeset viewer.