VARKON Version 1.15 1997-10-24
sur_cyl - Geometric procedure
Creates a surface
Description
Creates a cylindrical surface by translating (sweeping) a profile (line, arc or curve) a specified distance perpendicular to the plane of the profile. If the profile is not a plane curve or if the profile is a line VARKON automatically creates a "best possible" plane. If this is not satisfactory an arbitrary sweep direction may be specified.
Syntax
sur_cyl(id, profile, distance, reverse, dir:attributes);
REF id; REF profile; FLOAT distance; INT reverse; VECTOR dir;
Principal parameters
id - Local identity profile - Identity of arc or curve distance - Length of cylinder (surface V-direction). May be negative.
Optional parameters
reverse - Controls the parametric directions of the resulting surface 1 = No reversal of input (default) -1 = The profile curve (U-direction) is reversed 2 = The sweep (V-direction) is reversed 3 = Both are reversed dir - Sweeping direction if not perpendicular to the plane of the curve. Default = (0,0,0)
Attributes
PEN - Pen or colour number LEVEL - Level number BLANK - Visible(0) or invisible(1) SDASHL - Dashlength
Example
sur_cyl(#2, #1, 50);
Creates a surface by sweeping #1 50 units in the same direction as the normal of the plane of #1.
sur_cyl(#2, #1, 50, -1);
Geometrically the same surface but with parametrisation reversed with respect to U.
sur_cyl(#2,#1,50,1,vec(2,5,10));
Sweeps the curve 50 units in the direction of (2,5,10).
Comments
The parameter of the profile becomes the U-direction of the surface and V is mapped to the sweeping vector. The optional "reverse" parameter can be used to alter this.