VARKON Version 1.16 1998-08-22
sur_trim - Geometric procedure
Creates a surface
Description
Creates a surface by "trimming" a copy of another surface. The desired portion of the old surface is specified by two surface parameter points u1,u2 and v1,v2 relating to the position on the old surface where the new surface should start and end.
The parameter directions may be reversed. If the parameter value u1 is greater then u2 will be the start u (u=0) isoparameter curve in the trimmed surface and u1 will be the end isoparameter curve. If u1>u2 and v1>v2 both parameter directions be reversed.
The parameters may also be interchanged , i.e. the u isoparameter lines in the input surface will become v parameter lines in the trimmed surface and input surface v lines will become output surface u lines. This option is for the moment only implemented for CUB_SUR surfaces
Reverse and interchange options are very useful when mirrored surfaces shall be combined to one surface with function sur_comp.
Syntax
sur_trim(id, ref, u1, u2, v1, v2, case:attributes);
REF id; REF ref; FLOAT u1; FLOAT u2; FLOAT v1; FLOAT v2; INT case; Principal parameters
id - Local identity ref - Surface to copy and trim u1 - Surface U parameter start value u2 - Surface U parameter end value v1 - Surface V parameter start value v2 - Surface V parameter end value
Optional parameters
case - Surface trimming case Eq. 1: Normal trimming (default) Eq. 11: No reversal of parameter directions even if u1> u2 and/or v1>v2
Eq. 69: Trimming and interchange of parameter directions (reverse not allowed for this case)
Attributes
PEN - Pen or colour number LEVEL - Level number BLANK - Visible (0) or invisible (1) SFONT - Solid boundary and dashed midcurves (0) SDASHL - Dash length
Example
sur_trim(#3, #2, 2.3, 4.1, 0.0, 6.7);
Creates a new surface #3, which is limited by the iso-parametric curves U= 2.3, U= 4.1, V= 0.0 and V= 6.7. The shape of limited part is identical to the shape of the old surface #2.
sur_trim(#8, #5, 4.0, 0.0, 0.0, 7.0);
Creates a trimmed surface where the U parameter direction is reversed
sur_trim(#9, #8, 0.0, 4.0, 0.0, 7.0, 69);
The parameter lines will be interchanged.
Comments
Surface types (LFT_SUR, RAT_SUR and CON_SUR) can only be trimmed along the original patch boundaries, i.e. limited by integer valued iso-parametric curves (U=0.0, 1.0, 2.0, .. V= 0.0, 1.0, 2.0, 3.0, .....)
VARKON Homepage | Index |