RhinoNurbsCurve

class compas_rhino.geometry.RhinoNurbsCurve(*args, **kwargs)[source]

Bases: NurbsCurve, RhinoCurve

Class representing a NURBS curve based on the NurbsCurve of Rhino.Geometry.

Parameters

name (str, optional) – Name of the curve.

Attributes
  • points (list[Point], read-only) – The control points of the curve.

  • weights (list[float], read-only) – The weights of the control points.

  • knots (list[float], read-only) – The knot vector, without duplicates.

  • multiplicities (list[int], read-only) – The multiplicities of the knots in the knot vector.

  • knotsequence (list[float], read-only) – The knot vector, with repeating values according to the multiplicities.

  • continuity (int, read-only) – The degree of continuity of the curve.

  • degree (int, read-only) – The degree of the curve.

  • order (int, read-only) – The order of the curve (degree + 1).

  • is_rational (bool, read-only) – True is the curve is rational.

References

Methods

from_interpolation

Construct a NURBS curve by interpolating a set of points.

from_line

Construct a NURBS curve from a line.

from_parameters

Construct a NURBS curve from explicit curve parameters.

from_points

Construct a NURBS curve from control points.

Inherited Methods

aabb

Compute the axis aligned bounding box of the curve.

closest_point

Compute the closest point on the curve to a given point.

copy

Make an independent copy of the current curve.

curvature_at

Compute the curvature at a point on the curve.

divide_by_count

Divide the curve into a specific number of equal length segments.

divide_by_length

Divide the curve into segments of specified length.

fair

frame_at

Compute the local frame at a point on the curve.

from_arc

Construct a NURBS curve from an arc.

from_circle

Construct a NURBS curve from a circle.

from_data

Construct a NURBS curve from its data representation.

from_ellipse

Construct a NURBS curve from an ellipse.

from_json

Construct an object from serialized data contained in a JSON file.

from_jsonstring

Construct an object from serialized data contained in a JSON string.

from_obj

Load a curve from an OBJ file.

from_rhino

Construct a curve from an existing Rhino curve.

from_step

Load a NURBS curve from an STP file.

length

Compute the length of the curve.

locus

Compute the locus of points on the curve.

offset

point_at

Compute a point on the curve.

reverse

Reverse the parametrisation of the curve.

reversed

Reverse a copy of the curve.

smooth

space

Compute evenly spaced parameters over the curve domain.

split

tangent_at

Compute the tangent vector at a point on the curve.

to_data

Convert an object to its native data representation.

to_json

Serialize the data representation of an object to a JSON file.

to_jsonstring

Serialize the data representation of an object to a JSON string.

to_obj

Write the curve geometry to an OBJ file.

to_step

Write the curve geometry to a STP file.

torsion_at

Compute the torsion of the curve at a parameter.

transform

Transform this curve.

transformed

Returns a transformed copy of this geometry.

trim

validate_data

Validate the object's data against its data schema.

validate_json

Validate the object's data against its json schema.