Synopsis
PDX_MSGT gdx_LocateDeg1CurveCusps(long option, MDA_PTR gdx_db_ptr, double toler, double **cusps, long *numcusps)
Purpose
Locate cusps of a degree 1 GDX curve.
Description
This routine finds cusps (defined by an angular tolerance) which are located at the join of two linear segments of the degree 1 curve.
Input
option
GDX_UNNORM
Return normalized parameter values for the cusps that must be unnormalized for evaluation.
gdx_db_ptr
The GDX curve database pointer.
toler
Cosine angle tolerance. The angle between two neighboring linear segments can be between 0 degrees (no cusp) and 180 degrees. It is considered a cusp if the cosine of the angle between the segments is less than toler.
Output
cusps
A 1D array containing the parameter values corresponding to cusps. The number of values in cusps is numcusps. The array cusps is allocated in this routine (but only if at least one cusp is found). It must be deallocated in the calling program when it is no longer needed.
numcusps
The number of parameter values in the array cusps. These correspond to cusps.
Return
GDX_NOERR
GDX_BADDATA
Low level error return
.fi