Commit 54507e3a authored by Tung Nguyen's avatar Tung Nguyen
Browse files

cost calculation checked, fixed issue when RDPCM is on

parent 6b4283a7
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -68,7 +68,7 @@ double RdCost::calcRdCost( uint64_t fracBits, Distortion distortion )
#if JVET_AHG14_LOSSLESS
  if( m_costMode == COST_LOSSLESS_CODING && 0 != distortion )
  {
    return MAX_DOUBLE / 8;
    return MAX_DOUBLE;
  }
#endif
#if WCG_EXT
+2 −2
Original line number Diff line number Diff line
@@ -3188,7 +3188,7 @@ void IntraSearch::xIntraCodingTUBlock(TransformUnit &tu, const ComponentID &comp
#endif
    }
#if JVET_AHG14_LOSSLESS
    if( !( m_pcEncCfg->getCostMode() == COST_LOSSLESS_CODING && tu.mtsIdx[compID] == 0 ) )
    if( !( m_pcEncCfg->getCostMode() == COST_LOSSLESS_CODING && tu.mtsIdx[compID] == 0 ) || tu.cu->bdpcmMode != 0 )
    {
      m_pcTrQuant->transformNxN(tu, compID, cQP, uiAbsSum, m_CABACEstimator->getCtx(), loadTr);
    }
@@ -3207,7 +3207,7 @@ void IntraSearch::xIntraCodingTUBlock(TransformUnit &tu, const ComponentID &comp
  }

#if JVET_AHG14_LOSSLESS
  if( m_pcEncCfg->getCostMode() == COST_LOSSLESS_CODING && tu.mtsIdx[compID] == 0 )
  if( ( m_pcEncCfg->getCostMode() == COST_LOSSLESS_CODING && tu.mtsIdx[compID] == 0 ) && 0 == tu.cu->bdpcmMode )
  {
    uiAbsSum = 0;
    tu.getCoeffs( compID ).fill( 0 );