98 lines
9.8 KiB
HTML
98 lines
9.8 KiB
HTML
|
|
<!doctype html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
|
<html><head><title>Python: module geosolver.intersections</title>
|
|
</head><body bgcolor="#f0f0f8">
|
|
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
|
|
<tr bgcolor="#7799ee">
|
|
<td valign=bottom> <br>
|
|
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong><a href="geosolver.html"><font color="#ffffff">geosolver</font></a>.intersections</strong></big></big></font></td
|
|
><td align=right valign=bottom
|
|
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/rick/Programming/Python/GeoSolver/geosolver/intersections.py">/home/rick/Programming/Python/GeoSolver/geosolver/intersections.py</a></font></td></tr></table>
|
|
<p></p>
|
|
<p>
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
|
<tr bgcolor="#aa55cc">
|
|
<td colspan=3 valign=bottom> <br>
|
|
<font color="#fffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
|
|
|
|
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
|
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="math.html">math</a><br>
|
|
</td><td width="25%" valign=top><a href="re.html">re</a><br>
|
|
</td><td width="25%" valign=top><a href="sys.html">sys</a><br>
|
|
</td><td width="25%" valign=top><a href="geosolver.vector.html">geosolver.vector</a><br>
|
|
</td></tr></table></td></tr></table><p>
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
|
<tr bgcolor="#eeaa77">
|
|
<td colspan=3 valign=bottom> <br>
|
|
<font color="#ffffff" face="helvetica, arial"><big><strong>Functions</strong></big></font></td></tr>
|
|
|
|
<tr><td bgcolor="#eeaa77"><tt> </tt></td><td> </td>
|
|
<td width="100%"><dl><dt><a name="-angle_3p"><strong>angle_3p</strong></a>(p1, p2, p3)</dt><dd><tt>Returns the angle, in radians, rotating vector p2p1 to vector p2p3.<br>
|
|
arg keywords:<br>
|
|
p1 - a vector<br>
|
|
p2 - a vector<br>
|
|
p3 - a vector<br>
|
|
returns: a number<br>
|
|
In 2D, the angle is a signed angle, range [-pi,pi], corresponding<br>
|
|
to a clockwise rotation. If p1-p2-p3 is clockwise, then angle > 0.<br>
|
|
In 3D, the angle is unsigned, range [0,pi]</tt></dd></dl>
|
|
<dl><dt><a name="-cc_int"><strong>cc_int</strong></a>(p1, r1, p2, r2)</dt><dd><tt>Intersect circle (p1,r1) circle (p2,r2)<br>
|
|
where p1 and p2 are 2-vectors and r1 and r2 are scalars<br>
|
|
Returns a list of zero, one or two solution points.</tt></dd></dl>
|
|
<dl><dt><a name="-cl_int"><strong>cl_int</strong></a>(p1, r, p2, v)</dt><dd><tt>Intersect a circle (p1,r) with line (p2,v)<br>
|
|
where p1, p2 and v are 2-vectors, r is a scalar<br>
|
|
Returns a list of zero, one or two solution points</tt></dd></dl>
|
|
<dl><dt><a name="-cr_int"><strong>cr_int</strong></a>(p1, r, p2, v)</dt><dd><tt>Intersect a circle (p1,r) with ray (p2,v) (a half-line)<br>
|
|
where p1, p2 and v are 2-vectors, r is a scalar<br>
|
|
Returns a list of zero, one or two solutions.</tt></dd></dl>
|
|
<dl><dt><a name="-cs_transform_matrix"><strong>cs_transform_matrix</strong></a>(from_cs, to_cs)</dt><dd><tt>returns a transform matrix from from_cs to to_cs</tt></dd></dl>
|
|
<dl><dt><a name="-distance_2p"><strong>distance_2p</strong></a>(p1, p2)</dt><dd><tt>Returns the euclidean distance between two points<br>
|
|
arg keywords:<br>
|
|
p1 - a vector<br>
|
|
p2 - a vector<br>
|
|
returns: a number</tt></dd></dl>
|
|
<dl><dt><a name="-is_acute"><strong>is_acute</strong></a>(p1, p2, p3)</dt><dd><tt>returns True iff angle p1,p2,p3 is acute, i.e. less than pi/2</tt></dd></dl>
|
|
<dl><dt><a name="-is_clockwise"><strong>is_clockwise</strong></a>(p1, p2, p3)</dt><dd><tt>returns True iff triangle p1,p2,p3 is clockwise oriented</tt></dd></dl>
|
|
<dl><dt><a name="-is_counterclockwise"><strong>is_counterclockwise</strong></a>(p1, p2, p3)</dt><dd><tt>returns True iff triangle p1,p2,p3 is counterclockwise oriented</tt></dd></dl>
|
|
<dl><dt><a name="-is_flat"><strong>is_flat</strong></a>(p1, p2, p3)</dt><dd><tt>returns True iff triangle p1,p2,p3 is flat (neither clockwise of counterclockwise oriented)</tt></dd></dl>
|
|
<dl><dt><a name="-is_left_handed"><strong>is_left_handed</strong></a>(p1, p2, p3, p4)</dt><dd><tt>return True if tetrahedron p1 p2 p3 p4 is left handed</tt></dd></dl>
|
|
<dl><dt><a name="-is_obtuse"><strong>is_obtuse</strong></a>(p1, p2, p3)</dt><dd><tt>returns True iff angle p1,p2,p3 is obtuse, i.e. greater than pi/2</tt></dd></dl>
|
|
<dl><dt><a name="-is_right_handed"><strong>is_right_handed</strong></a>(p1, p2, p3, p4)</dt><dd><tt>return True if tetrahedron p1 p2 p3 p4 is right handed</tt></dd></dl>
|
|
<dl><dt><a name="-ll_int"><strong>ll_int</strong></a>(p1, v1, p2, v2)</dt><dd><tt>Intersect line though p1 direction v1 with line through p2 direction v2.<br>
|
|
Returns a list of zero or one solutions</tt></dd></dl>
|
|
<dl><dt><a name="-lr_int"><strong>lr_int</strong></a>(p1, v1, p2, v2)</dt><dd><tt>Intersect line though p1 direction v1 with ray through p2 direction v2.<br>
|
|
Returns a list of zero or one solutions</tt></dd></dl>
|
|
<dl><dt><a name="-make_hcs_2d"><strong>make_hcs_2d</strong></a>(a, b)</dt><dd><tt>build a 2D homogeneus coordiate system from two vectors</tt></dd></dl>
|
|
<dl><dt><a name="-make_hcs_2d_scaled"><strong>make_hcs_2d_scaled</strong></a>(a, b)</dt><dd><tt>build a 2D homogeneus coordiate system from two vectors, but scale with distance between input point</tt></dd></dl>
|
|
<dl><dt><a name="-make_hcs_3d"><strong>make_hcs_3d</strong></a>(a, b, c)</dt><dd><tt>build a 3D homogeneus coordiate system from three vectors</tt></dd></dl>
|
|
<dl><dt><a name="-make_hcs_3d_scaled"><strong>make_hcs_3d_scaled</strong></a>(a, b, c)</dt><dd><tt>build a 3D homogeneus coordiate system from three vectors</tt></dd></dl>
|
|
<dl><dt><a name="-pivot_scale_3D"><strong>pivot_scale_3D</strong></a>(pivot, scale)</dt></dl>
|
|
<dl><dt><a name="-rotate_2D"><strong>rotate_2D</strong></a>(angle)</dt></dl>
|
|
<dl><dt><a name="-rr_int"><strong>rr_int</strong></a>(p1, v1, p2, v2)</dt><dd><tt>Intersect ray though p1 direction v1 with ray through p2 direction v2.<br>
|
|
Returns a list of zero or one solutions</tt></dd></dl>
|
|
<dl><dt><a name="-scale_3D"><strong>scale_3D</strong></a>(sx, sy, sz)</dt></dl>
|
|
<dl><dt><a name="-sign"><strong>sign</strong></a>(x)</dt><dd><tt>Returns 1 if x>0, return -1 if x<=0</tt></dd></dl>
|
|
<dl><dt><a name="-sss_int"><strong>sss_int</strong></a>(p1, r1, p2, r2, p3, r3)</dt><dd><tt>Intersect three spheres, centered in p1, p2, p3 with radius r1,r2,r3 respectively. <br>
|
|
Returns a list of zero, one or two solution points.</tt></dd></dl>
|
|
<dl><dt><a name="-test1"><strong>test1</strong></a>()</dt></dl>
|
|
<dl><dt><a name="-test_ll_int"><strong>test_ll_int</strong></a>()</dt><dd><tt>test random line-line intersection. returns True iff succesful</tt></dd></dl>
|
|
<dl><dt><a name="-test_rr_int"><strong>test_rr_int</strong></a>()</dt><dd><tt>test random ray-ray intersection. returns True iff succesful</tt></dd></dl>
|
|
<dl><dt><a name="-test_sss_int"><strong>test_sss_int</strong></a>()</dt></dl>
|
|
<dl><dt><a name="-transform_point"><strong>transform_point</strong></a>(point, transform)</dt><dd><tt>transform a point from from_cs to to_cs</tt></dd></dl>
|
|
<dl><dt><a name="-translate_2D"><strong>translate_2D</strong></a>(dx, dy)</dt></dl>
|
|
<dl><dt><a name="-translate_3D"><strong>translate_3D</strong></a>(dx, dy, dz)</dt></dl>
|
|
<dl><dt><a name="-uniform_scale_3D"><strong>uniform_scale_3D</strong></a>(scale)</dt></dl>
|
|
</td></tr></table><p>
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
|
<tr bgcolor="#55aa55">
|
|
<td colspan=3 valign=bottom> <br>
|
|
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
|
|
|
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
|
<td width="100%"><strong>NegInf</strong> = geosolver.tolerance.NegInf<br>
|
|
<strong>PosInf</strong> = geosolver.tolerance.PosInf<br>
|
|
<strong>default_tol</strong> = 9.9999999999999995e-07<br>
|
|
<strong>diag_selector</strong> = <_sre.SRE_Pattern object at 0xb7ec9b60><br>
|
|
<strong>diag_stream</strong> = <open file '<stdout>', mode 'w' at 0xb7eb3068></td></tr></table>
|
|
</body></html> |