Re: [x265] [PATCH] fix: hash/binary mismatch for new CU structure holds CU-specific info

2014-09-03 Thread chen
This patch fixed bug report at Doom9.

At 2014-09-03 22:50:28,as...@multicorewareinc.com wrote:
# HG changeset patch
# User Ashok Kumar Mishraas...@multicorewareinc.com
# Date 1409753842 -19800
#  Wed Sep 03 19:47:22 2014 +0530
# Node ID 00c381bf615840180bb6ce924dc9be84c060938f
# Parent  62c4779fb0bb35d5d8a69678e9e8aa81272f0115
fix: hash/binary mismatch for new CU structure holds CU-specific info

___
x265-devel mailing list
x265-devel@videolan.org
https://mailman.videolan.org/listinfo/x265-devel


Re: [x265] [PATCH] fix: hash/binary mismatch for new CU structure holds CU-specific info

2014-09-03 Thread Deepthi Nandakumar
Thanks, Ashok. Queued.


On Wed, Sep 3, 2014 at 8:20 PM, as...@multicorewareinc.com wrote:

 # HG changeset patch
 # User Ashok Kumar Mishraas...@multicorewareinc.com
 # Date 1409753842 -19800
 #  Wed Sep 03 19:47:22 2014 +0530
 # Node ID 00c381bf615840180bb6ce924dc9be84c060938f
 # Parent  62c4779fb0bb35d5d8a69678e9e8aa81272f0115
 fix: hash/binary mismatch for new CU structure holds CU-specific info

 diff -r 62c4779fb0bb -r 00c381bf6158 source/encoder/analysis.cpp
 --- a/source/encoder/analysis.cpp   Thu Aug 28 13:14:34 2014 +0530
 +++ b/source/encoder/analysis.cpp   Wed Sep 03 19:47:22 2014 +0530
 @@ -420,13 +420,13 @@
  checkIntra(outBestCU, outTempCU, SIZE_2Nx2N, cu);
  if (depth == g_maxCUDepth)
  {
 -checkIntra(outBestCU, outTempCU, SIZE_NxN, cu);
 +checkIntra(outBestCU, outTempCU, SIZE_NxN, cu);
  }
  else
  {
 -m_entropyCoder-resetBits();
 -m_entropyCoder-codeSplitFlag(outBestCU, 0, depth);
 -outBestCU-m_totalBits +=
 m_entropyCoder-getNumberOfWrittenBits(); // split bits
 +m_entropyCoder-resetBits();
 +m_entropyCoder-codeSplitFlag(outBestCU, 0, depth);
 +outBestCU-m_totalBits +=
 m_entropyCoder-getNumberOfWrittenBits(); // split bits
  }
  if (m_rdCost.m_psyRd)
  outBestCU-m_totalPsyCost =
 m_rdCost.calcPsyRdCost(outBestCU-m_totalDistortion,
 outBestCU-m_totalBits, outBestCU-m_psyEnergy);
 @@ -437,6 +437,7 @@
  // copy original YUV samples in lossless mode
  if (outBestCU-isLosslessCoded(0))
  fillOrigYUVBuffer(outBestCU, m_origYuv[depth]);
 +
  // further split
  if (cu_split_flag)
  {
 @@ -445,18 +446,17 @@
  TComDataCU* subTempPartCU = m_tempCU[nextDepth];
  for (uint32_t partUnitIdx = 0; partUnitIdx  4; partUnitIdx++)
  {
 -int qp = outTempCU-getQP(0);
 -subBestPartCU-initSubCU(outTempCU, partUnitIdx, nextDepth,
 qp); // clear sub partition datas or init.
 -if (cu-flags  CU::PRESENT)
 +CU *child_cu = cuPicsym-m_CULocalData + cu-childIdx +
 partUnitIdx;
 +
 +if (child_cu-flags  CU::PRESENT)
  {
 +int qp = outTempCU-getQP(0);
 +subBestPartCU-initSubCU(outTempCU, partUnitIdx,
 nextDepth, qp); // clear sub partition datas or init.
  subTempPartCU-initSubCU(outTempCU, partUnitIdx,
 nextDepth, qp); // clear sub partition datas or init.
  if (0 == partUnitIdx) //initialize RD with previous depth
 buffer

  
 m_rdEntropyCoders[nextDepth][CI_CURR_BEST].load(m_rdEntropyCoders[depth][CI_CURR_BEST]);
  else

  
 m_rdEntropyCoders[nextDepth][CI_CURR_BEST].load(m_rdEntropyCoders[nextDepth][CI_NEXT_BEST]);
 -CU *child_cu = cuPicsym-m_CULocalData + cu-childIdx +
 partUnitIdx;
 -if (!(child_cu-flags  CU::PRESENT))
 -continue;

  compressIntraCU(subBestPartCU, subTempPartCU, nextDepth,
 bInsidePicture, cuPicsym, child_cu);
  outTempCU-copyPartFrom(subBestPartCU, partUnitIdx,
 nextDepth); // Keep best part data to current temporary data.
 ___
 x265-devel mailing list
 x265-devel@videolan.org
 https://mailman.videolan.org/listinfo/x265-devel

___
x265-devel mailing list
x265-devel@videolan.org
https://mailman.videolan.org/listinfo/x265-devel