[x265] [PATCH] analysis: fix output change in --cu-lossless and analysis-load mode for Intra slice

kavitha at multicorewareinc.com kavitha at multicorewareinc.com
Mon Oct 19 14:57:40 CEST 2015


# HG changeset patch
# User Kavitha Sampath <kavitha at multicorewareinc.com>
# Date 1445238772 -19800
#      Mon Oct 19 12:42:52 2015 +0530
# Node ID 8c6e6165dcb4e93f61f253028a2bec6080a174dd
# Parent  04575a459a160162391fcf1a12e8e6f2e81e95b4
analysis: fix output change in --cu-lossless and analysis-load mode for Intra slice

diff -r 04575a459a16 -r 8c6e6165dcb4 source/common/cudata.cpp
--- a/source/common/cudata.cpp	Wed Sep 30 11:22:16 2015 +0530
+++ b/source/common/cudata.cpp	Mon Oct 19 12:42:52 2015 +0530
@@ -374,6 +374,8 @@
     /* force TQBypass to true */
     m_partSet(m_tqBypass, true);
 
+    m_partSet(m_chromaIntraDir, (uint8_t)ALL_IDX);
+
     /* clear residual coding flags */
     m_partSet(m_predMode, cu.m_predMode[0] & (MODE_INTRA | MODE_INTER));
     m_partSet(m_tuDepth, 0);
diff -r 04575a459a16 -r 8c6e6165dcb4 source/encoder/analysis.cpp
--- a/source/encoder/analysis.cpp	Wed Sep 30 11:22:16 2015 +0530
+++ b/source/encoder/analysis.cpp	Mon Oct 19 12:42:52 2015 +0530
@@ -237,9 +237,6 @@
     bool bAlreadyDecided = parentCTU.m_lumaIntraDir[cuGeom.absPartIdx] != (uint8_t)ALL_IDX;
     bool bDecidedDepth = parentCTU.m_cuDepth[cuGeom.absPartIdx] == depth;
 
-    // stop recursion if we reach the depth of previous analysis decision
-    mightSplit &= !(bAlreadyDecided && bDecidedDepth);
-
     if (bAlreadyDecided)
     {
         if (bDecidedDepth)
@@ -278,6 +275,9 @@
             addSplitFlagCost(*md.bestMode, cuGeom.depth);
     }
 
+    // stop recursion if we reach the depth of previous analysis decision
+    mightSplit &= !(bAlreadyDecided && bDecidedDepth);
+
     if (mightSplit)
     {
         Mode* splitPred = &md.pred[PRED_SPLIT];


More information about the x265-devel mailing list