<div dir="ltr"><span style="font-size:12.8px">Please ignore the this patch. I'll resend this patch with minor corrections.</span><br><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Thanks</span></div><div><span style="font-size:12.8px">Ashok.</span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Nov 19, 2015 at 5:15 PM, <span dir="ltr"><<a href="mailto:ashok@multicorewareinc.com" target="_blank">ashok@multicorewareinc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"># HG changeset patch<br>
# User Ashok Kumar Mishra<<a href="mailto:ashok@multicorewareinc.com">ashok@multicorewareinc.com</a>><br>
# Date 1445505834 -19800<br>
# Thu Oct 22 14:53:54 2015 +0530<br>
# Node ID ec452c4fd379d2e4c456722ffc7f7dc49e9c9d37<br>
# Parent c1575815b250fb02c1fdae803aead10a4997c835<br>
SAO: remove resetSaoUnit()<br>
<br>
diff -r c1575815b250 -r ec452c4fd379 source/encoder/sao.cpp<br>
--- a/source/encoder/sao.cpp Thu Oct 29 17:15:15 2015 +0530<br>
+++ b/source/encoder/sao.cpp Thu Oct 22 14:53:54 2015 +0530<br>
@@ -704,15 +704,15 @@<br>
std::swap(m_tmpU1[plane], m_tmpU2[plane]);<br>
}<br>
<br>
-void SAO::resetSaoUnit(SaoCtuParam* saoUnit)<br>
-{<br>
- saoUnit->mergeMode = SAO_MERGE_NONE;<br>
- saoUnit->typeIdx = -1;<br>
- saoUnit->bandPos = 0;<br>
-<br>
- for (int i = 0; i < SAO_NUM_OFFSET; i++)<br>
- saoUnit->offset[i] = 0;<br>
-}<br>
+//void SAO::resetSaoUnit(SaoCtuParam* saoUnit)<br>
+//{<br>
+// saoUnit->mergeMode = SAO_MERGE_NONE;<br>
+// saoUnit->typeIdx = -1;<br>
+// saoUnit->bandPos = 0;<br>
+//<br>
+// for (int i = 0; i < SAO_NUM_OFFSET; i++)<br>
+// saoUnit->offset[i] = 0;<br>
+//}<br>
<br>
void SAO::copySaoUnit(SaoCtuParam* saoUnitDst, const SaoCtuParam* saoUnitSrc)<br>
{<br>
@@ -1172,9 +1172,14 @@<br>
}<br>
}<br>
<br>
- saoParam->ctuParam[plane][addr].mergeMode = SAO_MERGE_NONE;<br>
- saoParam->ctuParam[plane][addr].typeIdx = -1;<br>
- saoParam->ctuParam[plane][addr].bandPos = 0;<br>
+// saoParam->ctuParam[plane][addr].mergeMode = SAO_MERGE_NONE;<br>
+// saoParam->ctuParam[plane][addr].typeIdx = -1;<br>
+// saoParam->ctuParam[plane][addr].bandPos = 0;<br>
+<br>
+ saoParam->ctuParam[plane][addr].reset();<br>
+<br>
+ mergeSaoParam[plane][0].reset();<br>
+ mergeSaoParam[plane][1].reset();<br>
if (saoParam->bSaoFlag[plane > 0])<br>
calcSaoStatsCu(addr, plane);<br>
}<br>
@@ -1326,7 +1331,7 @@<br>
int currentDistortionTableBo[MAX_NUM_SAO_CLASS];<br>
double currentRdCostTableBo[MAX_NUM_SAO_CLASS];<br>
<br>
- resetSaoUnit(lclCtuParam);<br>
+// resetSaoUnit(lclCtuParam);<br>
m_entropyCoder.load(m_rdContexts.temp);<br>
m_entropyCoder.resetBits();<br>
m_entropyCoder.codeSaoOffset(*lclCtuParam, 0);<br>
@@ -1413,8 +1418,8 @@<br>
<br>
mergeDist[mergeIdx + 1] = ((double)estDist / m_lumaLambda);<br>
}<br>
- else<br>
- resetSaoUnit(&mergeSaoParam[mergeIdx]);<br>
+// else<br>
+// resetSaoUnit(&mergeSaoParam[mergeIdx]);<br>
}<br>
}<br>
<br>
@@ -1428,8 +1433,8 @@<br>
int bestClassTableBo[2] = { 0, 0 };<br>
int currentDistortionTableBo[MAX_NUM_SAO_CLASS];<br>
<br>
- resetSaoUnit(lclCtuParam[0]);<br>
- resetSaoUnit(lclCtuParam[1]);<br>
+// resetSaoUnit(lclCtuParam[0]);<br>
+// resetSaoUnit(lclCtuParam[1]);<br>
m_entropyCoder.load(m_rdContexts.temp);<br>
m_entropyCoder.resetBits();<br>
m_entropyCoder.codeSaoOffset(*lclCtuParam[0], 1);<br>
@@ -1536,8 +1541,8 @@<br>
mergeSaoParam[plane][mergeIdx].mergeMode = mergeIdx ? SAO_MERGE_UP : SAO_MERGE_LEFT;<br>
mergeDist[mergeIdx + 1] += ((double)estDist / m_chromaLambda);<br>
}<br>
- else<br>
- resetSaoUnit(&mergeSaoParam[plane][mergeIdx]);<br>
+// else<br>
+// resetSaoUnit(&mergeSaoParam[plane][mergeIdx]);<br>
}<br>
}<br>
}<br>
</blockquote></div><br></div>