HMIN_writeNURBSsurface()

Specifies the information for a NURBS surface.

Syntax

void HMIN_writeNURBSsurface(unsigned int degree_u, unsigned int degree_v, unsigned int number_pts_u, unsigned int number_pts_v, double * points, double * weights, unsigned int number_knots_u, double * knots_u, unsigned int number_knots_v, double * knots_v, double start_u, double end_u, double start_v, double end_v);

Type

HyperMesh hminlib Function

Description

Specifies the information for a NURBS surface.

Inputs

degree_u
The degree of the NURBS surface in the u direction.
degree_v
The degree of the NURBS surface in the v direction.
number_pts_u
The size of the control point array in the u direction.
number_pts_v
The size of the control point array in the v direction.
points
The control points, in the form X1, Y1, Z1, X2, Y2, Z2, and so on; the list should vary first in the u direction. (That is, the index of the X value of point [u, v] is (v * number_pts_u + u) * 3.) There should be number_pts_u * number_pts_v * 3 doubles here.
weights
If the NURBS is rational, this is the weight given to each control point, in the same order as the control points. If the NURBS is polynomial, a null pointer should be passed in.
number_knots_u
The number of knots in the NURBS's controlling u-knot sequence.
knots_u
The u-knot sequence.
number_knots_v
The number of knots in the NURBS's controlling v-knot sequence.
knots_v
The v-knot sequence.
start_u
The u parameter value at the start of the portion of the surface under consideration.
end_u
The u parameter value at the end of the portion of the surface under consideration.
start_v
The v parameter value at the start of the portion of the surface under consideration.
end_v
The v parameter value at the end of the portion of the surface under consideration.

Example

A detailed description of the structure and meaning of NURBS surfaces is found in the HyperMesh User's Guide.

The NURBS format is very versatile. HyperMesh attempts to understand all NURBS surfaces, but you can ensure more accurate results and faster processing time by following these guidelines:

HyperMesh requires that its surfaces be C1 continuous. Thus multiple knots of multiplicity of the degree or greater force HyperMesh to modify the surfaces.

In particular, if one of the knot sequences has a knot with multiplicity greater than the degree of the surface in that direction, HyperMesh removes the resulting gap in the surface by averaging the points on each side of the gap.

If one of the knot sequences has a knot with multiplicity equal to the degree of the surface in that direction, HyperMesh attempts to remove a knot and a row or column of control points. If this would result in a change in the surface of greater than tolerance, HyperMesh is forced to break the surface into two or more faces. Such surfaces cannot be trimmed.

Multiple control points with multiplicity of the surface's degree or greater are not detected by HyperMesh at this time. Using them is not advised.

Parameterization on a surface should be relatively even. Arc length parameterization would be ideal, but it is not always possible.

Currently HyperMesh requires parameter space lines to trim NURBS surfaces. However, it is advisable to send object space lines as well; if then HyperMesh is unable to trim the surface, the object space lines are created in HyperMesh, and you may be able to trim the surface by hand with these lines, or re-create the surface from scratch.

This command is only valid after a call to HMIN_startsurf() and before the corresponding call to HMIN_endsurf(). Any trimming lines must be sent before the surface is sent.

Errors

None.