Please log a bug report and post a patch at <a href="http://vtk.org/Bug">vtk.org/Bug</a><br><br>Thanks<br><br><div class="gmail_quote">On Thu, Nov 12, 2009 at 8:55 PM, Paul Harris <span dir="ltr"><<a href="mailto:harris.pc@gmail.com">harris.pc@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi,<br><br>in vtkPlanesIntersection.cxx, around line 229, there is this loop:<br><br> for (plane=0; plane < nplanes; plane++)<br>
{<br> where[plane] = this->EvaluateFacePlane(plane, R);<br><br> if (allInside && (where[plane] != Inside))<br>
{<br> allInside = 0;<br> }<br><br> if (where[plane] == Outside)<br> {<br> intersects = 0;<br><br> break;<br> }<br> }<br><br><br>my question is,<br>why isn't there a break; after allInside=0 ?<br>
<br>and, why are you using the where[] array at all, since it is not referenced in any other code? (except to alloc and delete)<br><br>If you add a break and remove the where array, we can save a tiny bit of memory, simplify the code a little, and avoid calling EvaluateFacePlane() in a bunch of situations.<br>
<br>thanks,<br><font color="#888888">Paul<br><br>
</font><br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtk-developers" target="_blank">http://www.vtk.org/mailman/listinfo/vtk-developers</a><br>
<br>
<br></blockquote></div><br><br clear="all"><br>