GstarCAD 2027 · Command Reference
Commands > R Command > RULESURF
Function Description:
This command is used to create a mesh that represents the surface between two lines or two curves.


Uses can select two lines, arcs, splines, circles or polylines as two edges of meshes. If one selected edge is closed, another one should be closed too. The point can also be seemed as one edge.

The MESHTYPE system variable can specify the mesh type. By default, it is
set to 0 to create polyface or polygon meshes.
For closed curves, it is no need to consider about the selected objects. If the selected surface is a circle, the RULESURF
begins at the 0 degree quadrant point, this quadrant point is determined by the current X axis and
the current value of the SNAPANG system variable. If the selected surface is a closed polyline, the RULESURF
starts at the last vertex along the reverse direction of the polyline. If users select one circle and one polyline to create a
ruled mesh, it may generate in random pattern and it is better to use a closed semi-circle to replace the circle.
The RULESURF is constructed as a 2×N polygon meshes. A half number of
vertices are equally distributed along one defined surface by the RULESURF
command and the other half are equally distributed along the other curve. The
number of intervals is specified by the SURFTAB1 system variable. The division number is the same for each
curve. If the lengths of selected two curves are not the same, accordingly, the
distance of two vertices is not equal on the selected two curves.
The N direction of the mesh is the same as the direction of the boundary
curves. If the selected two curves are all closed or one closed and the other is a point, the generated
polygon mesh is closed in the N direction, as well the value of N is equal to
the SURFTAB1 value. If the selected two surfaces are all unclosed, the value of
N is equal to the SURFTAB1 value plus 1, because there needs N+1 mesh lines to
divide the curve into N equal parts.
The mesh vertex (0,0) is the endpoint of the first selected curve and it is the nearest one to the point
you used to select the curve.
Users can create polygon meshes by selecting objects on the same side. They can also create self-intersection polygon mesh by selecting objects in two opposite sides.

Command Access:
Icon:
Menu: Draw > Modeling > Meshes > Ruled Mesh
Ribbon: 3D > Mesh > RULESURF
Toolbar: /
Command: RULESURF
Alias: /
Command Prompts:
Select first defining curve:
Select second defining curve:
Related References:
Related Tasks:
Article ID: 3530
Created: September 26, 2026
Last Updated: September 25, 2026
Author: kbadmin
Online URL: https://kb.gstarcad.com.my/article/rulesurf-command-gstarcad-2027-3530.html