Synopsis
PDX_MSGT gdx_ConvertSurfCmpEdgCrvToParm(long option, MDA_PTR gdx_db_ptr, MDA_PTR gdx_new_surf_ptr, int model, double tolerance, int u_degree, int v_degree, int max_iters, void *gdx_parm_cec, double *max_dev)
Purpose
Convert a GDX surface composite edge curve entity to an all GDX Parametric Spline curve and surface composite edge curve entity.
Description
Given a GDX composite edge curve entity that references parametric or non-parametric spline curve and surface entities, converts the non-parametric entities to parametric spline entities. If the composite edge curve references GDX parametric spline curve and surface entities, the GDX parametric spline entities are duplicated in the new model and referenced by the new GDX composite edge curve.
Parameter space curves are recomputed: .RS 4 o If the base surface was a non-parametric spline surface that was converted to a parametric spline surfaces, .RE .RS 4 o The bounded surface type indicates references to model space curves only. .RE
Model space curves are recomputed: .RS 4 o If the model space curves are not GDX parametric spline curves .RE .RS 4 o If a new parameter space curve was computed and the preference flag is parameter space, .RE
The tolerance and max_iters values apply to the parametric curves or surface that are approximated. The tolerance MODEL_SPACE_PNT_TOL should be at least 2 orders of magnitude smaller than the tolerance value for reasonable results.
The GDX composite edge curve entity and all its subordinate entities must be valid GDX definitions.
The conversion is exact where the curve and surface entities convert exactly to the parametric definition, otherwise the conversion is an approximation to tolerance. The projection of new parameter space curves and/or creation of new model space curves from parameter space curves is an approximation to tolerance.
Input
option
GDX_COMMIT
Commit the GDX composite edge curve to the database
GDX_NEWPARMCRV
Recompute the parameter space trimming curve by projecting the parametric spline model space curve to the parametric spline surface in the cases where the base surface is already a parametric spline surface
GDX_NEWMODELCRV
Recompute the parametric spline model space trimming curve from the computed parametric spline parameter space curve when the parameter space curve is recomputed. The preference flag will be set to parameter space prefered.
GDX_OPENCLOSED
Open a closed surface if the projection of the model space curves generates multiple parameter space curves accross seam closure.
GDX_USEUDEG
Force the curve to be the Degree of the Surface in the U direction.
GDX_USEDEG1
Force the U or V degree of the converted surface to be degree 1 if the original surface is non-rational and degree 1 in U and/or V
gdx_db_ptr
The composite edge curve entity database pointer pointer
gdx_new_surf_ptr
The database pointer of the new GDX non-rational with U degree equal u_degree @ V degree equal v_degree NURBS surface entity that should be used for the converted composite edge curve surface or MDA_NULL_PTR. NOTE: This surface must be converted to a GDX parametric spline surface and all the edge curves updated by the calling function.
model
The model to create the new GDX composite edge curve entity in
tolerance
The conversion approximation tolerance. Note: The MODEL_SPACE_PNT_TOL should be at least 2 orders of magnitude less than this tolerance for correct results.
u_degree
The converted parametric spline curve degree and/or the converted parametric spline surface U degree
v_degree
The converted parametric spline surface V degree
max_iters
The maximum iterations for convergence test
Output
gdx_parm_cec
The new GDX parametric spline composite edge curve entity database pointer or structure pointer
max_dev
The maximum deviation of the model space curve to the surface
Tolerances
MODEL_SPACE_PNT_TOL
PARM_SPACE_PNT_TOL
ANGLE_TOL
ZERO_TOL
CONVERGE_TOL
KNOT_TOL
PNT_PROJ_TOL
PARALLEL_LINES_TOL
COLLINEAR_TOL
COPLANAR_TOL
.fi
Return
GDX_NOERR
Low level error return
.fi