<div dir="ltr"><div># HG changeset patch</div><div># User Aarthi Thirumalai</div><div># Date 1393263092 -19800</div><div># Mon Feb 24 23:01:32 2014 +0530</div><div># Node ID 2f813eb983817a48aeb483ba2ac28303d5b4d451</div>
<div># Parent dce74082c20eea1f7ef9eb10f9a9addc5e7c7bb7</div><div>rc: bug fix - clip qp before setting into TComPic:m_avgQpRc.</div><div><br></div><div>This fix resolves Encoder crash caused due to invalid qp being used in each CU.</div>
<div><br></div><div>diff -r dce74082c20e -r 2f813eb98381 source/encoder/ratecontrol.cpp</div><div>--- a/source/encoder/ratecontrol.cpp<span class="" style="white-space:pre"> </span>Mon Feb 24 17:50:55 2014 +0530</div><div>
+++ b/source/encoder/ratecontrol.cpp<span class="" style="white-space:pre"> </span>Mon Feb 24 23:01:32 2014 +0530</div><div>@@ -409,7 +409,8 @@</div><div> /* Update rce for use in rate control VBV later */</div><div>
rce->lastSatd = currentSatd;</div><div> double q = qScale2qp(rateEstimateQscale(pic, rce));</div><div>- qp = Clip3(MIN_QP, MAX_MAX_QP, (int)(q + 0.5));</div><div>+ q = Clip3((double)MIN_QP, (double)MAX_MAX_QP, q);</div>
<div>+ qp = int(q + 0.5);</div><div> rce->qpaRc = pic->m_avgQpRc = q;</div><div> /* copy value of lastRceq into thread local rce struct *to be used in RateControlEnd() */</div><div> rce->qRceq = lastRceq;</div>
<div>@@ -585,10 +586,10 @@</div><div> if (qCompress != 1 && framesDone == 0)</div><div> q = qp2qScale(ABR_INIT_QP) / fabs(cfg->param.rc.ipFactor);</div><div> }</div><div>- qpNoVbv = qScale2qp(q);</div>
<div> double lmin1 = lmin[sliceType];</div><div> double lmax1 = lmax[sliceType];</div><div> q = Clip3(lmin1, lmax1, q);</div><div>+ qpNoVbv = qScale2qp(q);</div><div> </div><div> q = clipQscale(pic, q);</div>
<div> </div><div><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Feb 24, 2014 at 10:38 PM, Derek Buitenhuis <span dir="ltr"><<a href="mailto:derek.buitenhuis@gmail.com" target="_blank">derek.buitenhuis@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="">On 2/24/2014 12:56 PM, <a href="mailto:aarthi@multicorewareinc.com">aarthi@multicorewareinc.com</a> wrote:<br>
> # HG changeset patch<br>
> # User Aarthi Thirumalai<br>
> # Date 1393244587 -19800<br>
> # Mon Feb 24 17:53:07 2014 +0530<br>
> # Node ID 3abef12d5b47106005c813bfd60ea49c31048f12<br>
> # Parent dce74082c20eea1f7ef9eb10f9a9addc5e7c7bb7<br>
> rc: bug fix for encoder crash<br>
<br>
</div>Please state *what* was fixed. It's not obvious from the commit.<br>
<br>
- Derek<br>
_______________________________________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" target="_blank">https://mailman.videolan.org/listinfo/x265-devel</a><br>
</blockquote></div><br></div></div>