I understand everything except the last part.  How do I know if I move epsilon along the vector I have my point?<br><br><div class="gmail_quote">On Fri, Feb 25, 2011 at 9:55 AM, David Doria <span dir="ltr">&lt;<a href="mailto:daviddoria@gmail.com">daviddoria@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="im"><div class="gmail_quote">On Fri, Feb 25, 2011 at 12:51 PM, Jonathan Morra <span dir="ltr">&lt;<a href="mailto:jonmorra@gmail.com" target="_blank">jonmorra@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Even if I make a vtkPolygon, I still have to loop over a whole bunch of points (potentially) to get one that is inside the contour.  I was wondering if there was a way to do this without loops.<div><div></div><div>
</div></div></blockquote></div><br><div><br></div></div><div>Ah, my mistake, I misread your original post.</div><div><br></div><div>If all you want is any point inside of the polygon, how about:</div>
<div>- Pick a point on the polygon (one of the points in your contour)</div><div>- Pick a random vector in the plane of the polygon</div><div>- Move epsilon along that vector</div><div>- Do the point in polygon test</div>

<div>- If it passes, you have your point</div><div>- If it fails, move -epsilon along the vector and you have your point</div><div><br></div><div>Does that make sense?</div><div><br><font color="#888888">David</font></div>

</blockquote></div><br>