Synopsis

PDX_MSGT gdx_IntersectNurbCurves(long option, T_GDX_NURB_CURVE *cur1, T_GDX_NURB_CURVE *cur2, double intxeps, double ptctol, long *numintx, double (**parms)[2], MTH_3DPNT (**pts)[2])

Purpose

Find all points of intersection of two 3D Nurbs curves.

Description

Finds all points of intersection of two Nurbs curves, C(s) and C(t). The curves may be 2D or 3D (but 3D points are returned). At an intersection, four items are returned: the s and t values, and the two corresponding curve points C(s) and C(t).

Input

option

Not used.

cur1

The first curve, C(s).

cur2

The second curve, C(t).

intxeps

Intersection tolerance. The parameters s and t represent an intersection point if C(s) and C(t) are within intxeps distance of one another. The bigger the intersection tolerance, the more intersection points are found. Recommended value for zero-tolerance intersecting curves is 10e-8.

ptctol

Point coincidence tolerance for the space in which the two curves lie. The bigger ptctol, the less intersection points are found. Recommended value for zero-tolerance intersecting curves is 10e-5.

Output

numintx

The number of intersections found.

parms

The s and t parameter values corresponding to intersection points. Memory allocated in this routine.

pts

The model space points C(s) and C(t) corresponding to intersection points. Memory allocated in this routine.

Return

      GDX_NOERR
      Low level error return
      .fi