RhinoNurbsSurface

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

Bases: compas.geometry.surfaces.nurbs.NurbsSurface

Class representing a NURBS surface.

Attributes
  • points (List[List[Point]]) – The control points of the surface.

  • weights (List[List[float]]) – The weights of the control points.

  • u_knots (List[float]) – The knot vector, in the U direction, without duplicates.

  • v_knots (List[float]) – The knot vector, in the V direction, without duplicates.

  • u_mults (List[int]) – The multiplicities of the knots in the knot vector of the U direction.

  • v_mults (List[int]) – The multiplicities of the knots in the knot vector of the V direction.

  • u_degree (int) – The degree of the polynomials in the U direction.

  • v_degree (int) – The degree of the polynomials in the V direction.

  • u_domain (Tuple[float, float]) – The parameter domain in the U direction.

  • v_domain (Tuple[float, float]) – The parameter domain in the V direction.

  • is_u_periodic (bool) – True if the surface is periodic in the U direction.

  • is_v_periodic (bool) – True if the surface is periodic in the V direction.

Attributes

data

The representation of the object as native Python data.

is_u_periodic

is_v_periodic

points

u_degree

u_domain

u_knots

u_knotsequence

u_mults

v_degree

v_domain

v_knots

v_knotsequence

v_mults

weights

Inherited Attributes

DATASCHEMA

The schema of the data of this object.

JSONSCHEMA

The schema of the JSON representation of the data of this object.

JSONSCHEMANAME

dtype

The type of the object in the form of a '2-level' import and a class name.

guid

The globally unique identifier of the object.

jsondefinitions

Reusable schema definitions.

jsonstring

The representation of the object data in JSON format.

jsonvalidator

JSON schema validator for draft 7.

name

The name of the object.

Methods

aabb

Compute the axis aligned bounding box of the surface.

boundary

Compute the boundary curves of the surface.

closest_point

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

curvature_at

Compute the curvature at a point on the surface.

frame_at

Compute the local frame at a point on the curve.

from_data

Construct a BSpline surface from its data representation.

from_fill

Construct a NURBS surface from the infill between two NURBS curves.

from_parameters

Construct a NURBS surface from explicit parameters.

from_points

Construct a NURBS surface from control points.

from_rhino

Construct a NURBS surface from an existing Rhino surface.

from_step

Load a NURBS surface from a STP file.

point_at

Compute a point on the surface.

to_step

Write the surface geometry to a STP file.

u_isocurve

Compute the isoparametric curve at parameter u.

v_isocurve

Compute the isoparametric curve at parameter v.

Inherited Methods

copy

Make an independent copy of the surface.

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_meshgrid

Construct a NURBS surface from a mesh grid.

intersections_with_line

Compute the intersections with a line.

obb

Compute the oriented bounding box of the surface.

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_mesh

Convert the surface to a quad mesh.

to_triangles

Convert the surface to a list of triangles.

transform

Transform this surface.

transformed

Transform an independent copy of this surface.

u_space

Compute evenly spaced parameters over the surface domain in the U direction.

v_space

Compute evenly spaced parameters over the surface domain in the V direction.

validate_data

Validate the object's data against its data schema (self.DATASCHEMA).

validate_json

Validate the object's data against its json schema (self.JSONSCHEMA).

xyz

Compute point locations corresponding to evenly spaced parameters over the surface domain.