[x265] bug in IntraPred [DC]

chen chenm003 at 163.com
Wed Jul 4 10:00:36 CEST 2018


Hi,


There have a long time bug in our intra prediction DC mode, see details:




******************** HM ****************************


// Function for calculating DC value of the reference samples used in Intra prediction
//NOTE: Bit-Limit - 25-bit source
Pel TComPrediction::predIntraGetPredValDC( const Pel* pSrc, Int iSrcStride, UInt iWidth, UInt iHeight)
{
  assert(iWidth > 0 && iHeight > 0);
  Int iInd, iSum = 0;
  Pel pDcVal;


  for (iInd = 0;iInd < iWidth;iInd++)
  {
    iSum += pSrc[iInd-iSrcStride];
  }
  for (iInd = 0;iInd < iHeight;iInd++)
  {
    iSum += pSrc[iInd*iSrcStride-1];
  }


  pDcVal = (iSum + iWidth) / (iWidth + iHeight);


  return pDcVal;
}




*************************** x265 ******************************
dcVal = dcVal / (width + width);


*************************************************************




I have been double checked my origin x265 tree, it does not affect in there, so I guess we need fix it on the current tree.


Regards,
Min

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/x265-devel/attachments/20180704/cd005a4e/attachment.html>


More information about the x265-devel mailing list