<div class="gmail_quote">Dear David Daria:<br><br><div class="gmail_quote"><div><div class="h5">2012/4/20 David Doria <span dir="ltr">&lt;<a href="mailto:daviddoria@gmail.com" target="_blank">daviddoria@gmail.com</a>&gt;</span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="gmail_quote"><div>2012/4/19 Rong Xu <span dir="ltr">&lt;<a href="mailto:xurong1981@gmail.com" target="_blank">xurong1981@gmail.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


Dear all:<br><br>I am doing work on a judgement about relationship between a point and an arbitrary cube. I have known the 8 coordinates of&nbsp; the cube vertex and have draw it out, and also I have known the coordinate of one point. Then I want to judge whether this point is inside the cube or outside the cube. <br>



<br>One of my idea is first I rotate the arbitrary cube to make its three edges coincide with three axises (x, y, and z), and make one of its vertices on the origin of the coordinate system. But I don&#39;t know whether there are methods in VTK that can be used to realize this purpose ? Or does anyone have any other ideas on judging the relationship between the point and the cube ?<br>



<br>Thank you very much for your ideas !<br><br clear="all"></blockquote><div><br></div></div><div>I&#39;m not sure I followed completely, but it sounds like you might be looking for a &quot;point inside object&quot; test?</div>


<div><br></div></div><a href="http://www.vtk.org/Wiki/VTK/Examples/Cxx/PolyData/PointInsideObject" target="_blank">http://www.vtk.org/Wiki/VTK/Examples/Cxx/PolyData/PointInsideObject</a><span><font color="#888888"><br clear="all">

</font></span></blockquote></div></div><div><br>That&#39;a very useful to realize my purpose, and also save my much time !<br><br>Thank you very much!<br>&nbsp;</div><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">

<span><font color="#888888"><br>David<br>
</font></span></blockquote></div><div class="HOEnZb"><div class="h5"><br><br clear="all"><br>-- <br><br> ---------------------<br>Best Regards!<br><br>===============================================<br>Rong Xu,&nbsp; Ph.D Student<br>
Ohya Lab<br>Graduate School of Global Information
and Telecommunication<br>Studies (GITS), Waseda University<br>1-6-1 Nishi Waseda, Shinjuku-ku,
Tokyo, Japan (¨“169-8050)<br><br>Tel:&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; <a href="tel:%2B81-80-4208-1207" value="+818042081207" target="_blank">+81-80-4208-1207</a><br>E-mail:&nbsp; &nbsp;&nbsp; <a href="mailto:xurong1981@gmail.com" target="_blank">xurong1981@gmail.com</a><br>
&nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp; &nbsp; <a href="mailto:xurong@fuji.waseda.jp" target="_blank">xurong@fuji.waseda.jp</a><br>
===============================================<br><br>
</div></div></div><br><br clear="all"><br>-- <br><br> ---------------------<br>Best Regards!<br><br>===============================================<br>Rong Xu,&nbsp; Ph.D Student<br>Ohya Lab<br>Graduate School of Global Information
and Telecommunication<br>Studies (GITS), Waseda University<br>1-6-1 Nishi Waseda, Shinjuku-ku,
Tokyo, Japan (¨“169-8050)<br><br>Tel:&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; +81-80-4208-1207<br>E-mail:&nbsp; &nbsp;&nbsp; <a href="mailto:xurong1981@gmail.com" target="_blank">xurong1981@gmail.com</a><br>&nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp; &nbsp; <a href="mailto:xurong@fuji.waseda.jp" target="_blank">xurong@fuji.waseda.jp</a><br>
===============================================<br><br>