<div><div>The SADS will be used like this:</div><div><br></div><div>SADS(0, +0, -4, +0, +4, -2, -3, +2, -3);</div><div>SADS(1, -4, -2, +4, -2, -4, -1, +4, -1);</div><div>SADS(2, -4, +0, +4, +0, -4, +1, +4, +1);</div><div>SADS(3, -4, +2, +4, +2, -2, +3, +2, +3);</div><div><br></div><div>which all  x0, y0, x1, y1, x2, y2, x3, y3 have added the ¡°+¡± ¡°-¡± in the code, so that SADS macro expansion will add the "+" "-" in the code.</div></div><div><div><br></div><div><br></div><div style="font-size: 12px;font-family: Arial Narrow;padding:2px 0 2px 0;">------------------ Original ------------------</div><div style="font-size: 12px;background:#efefef;padding:8px;"><div><b>From: </b> "N Vijay Anand";<nvijay.anand@trispacetech.com>;</div><div><b>Send time:</b> Wednesday, Jul 27, 2016 9:10 PM</div><div><b>To:</b> "x265-devel"<x265-devel@videolan.org>; <wbr></div><div></div><div><b>Subject: </b> [x265] Motion.cpp file</div></div><div><br></div><div dir="ltr">In the file source\encoder\motion.cpp<div><br></div><div>The Following lines  (872 to 880)</div><div><br></div><div><div>#define SADS(k, x0, y0, x1, y1, x2, y2, x3, y3) \</div><div>    sad_x4(fenc, \</div><div>           fref_base x0 * i + (y0 - 2 * k + 4) * dy, \</div><div>           fref_base x1 * i + (y1 - 2 * k + 4) * dy, \</div><div>           fref_base x2 * i + (y2 - 2 * k + 4) * dy, \</div><div>           fref_base x3 * i + (y3 - 2 * k + 4) * dy, \</div><div>           stride, costs + 4 * k); \</div><div>    fref_base += 2 * dy;</div><div>#define ADD_MVCOST(k, x, y) costs[k] += p_cost_omvx[x * 4 * i] + p_cost_omvy[y * 4 * i]</div><div><br></div><div>there seem some operator (possibly "+") missing between fref_base and x0,</div><div>fref_base and x1,</div><div>fref_base and x2,</div><div>fref_base and x3</div><div><br></div><div>Im not able to understand why it's so?</div><div>Any pointers ?</div><div><br></div><div>Vijay</div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div>Principal Architect and Director,</div><div>TriSpace Technologies Pvt Ltd.,</div><div><br></div><div><br></div></div></div></div></div></div></div>
</div></div></div>