RhinoBrep

class compas_rhino.geometry.RhinoBrep[source]

Bases: Brep

Rhino Brep backend class.

Wraps around and allows serialization and de-serialization of a Rhino.Geometry.Brep.

Attributes:
native_brepRhino.Geometry.Brep

The underlying Rhino Brep instance.

verticeslist[compas_rhino.geometry.RhinoBrepVertex], read-only

The list of vertices which comprise this Brep.

pointslist[compas.geometry.Point], read-only

The list of vertex geometries as points in 3D space.

edgeslist[compas_rhino.geometry.RhinoBrepEdge], read-only

The list of edges which comprise this brep.

trimslist[compas_rhino.geometry.RhinoBrepTrim], read-only

The list of trims which comprise this brep.

loopslist[compas_rhino.geometry.RhinoBrepLoop], read-only

The list of loops which comprise this brep.

faceslist[compas_rhino.geometry.RhinoBrepFace], read-only

The list of faces which comprise this brep.

framecompas.geometry.Frame, read-only

The brep’s origin (Frame.worldXY()).

areafloat, read-only

The calculated area of this brep.

volumefloat, read-only

The calculated volume of this brep.

Methods

contains

Check if the Brep contains a given geometric primitive.

copy

Creates a deep-copy of this Brep using the native Rhino.Geometry.Brep copying mechanism.

from_boolean_difference

Construct a Brep from the boolean difference of two groups of Breps.

from_boolean_intersection

Construct a Brep from the boolean intersection of two groups of Breps.

from_boolean_union

Construct a Brep from the boolean union of two groups of Breps.

from_box

Create a RhinoBrep from a box.

from_cylinder

Create a RhinoBrep from a box.

from_extrusion

Create a RhinoBrep from an extrusion.

from_mesh

Create a RhinoBrep from a mesh.

from_native

Constructs a RhinoBrep from an instance of a Rhino.Geometry.Brep.

from_sphere

Create a RhinoBrep from a sphere.

slice

Slice through the Brep with a plane.

split

Splits a Brep into pieces using a Brep as a cutter.

to_meshes

Convert the faces of this Brep shape to meshes.

transform

Transform this Brep by given transformation matrix

trim

Trim this brep by the given trimming plane.

trimmed

Returns a trimmed copy of this brep by the given trimming plane.

Inherited Methods

ToString

Converts the instance to a string.

compute_aabb

Compute the axis-aligned bounding box of the geometry.

compute_obb

Compute the oriented bounding box of the geometry.

contours

Generate contour lines by slicing the Brep shape with a series of planes.

cull_unused_edges

Remove all unused edges.

cull_unused_faces

Remove all unused faces.

cull_unused_loops

Remove all unused loops.

cull_unused_vertices

Remove all unused vertices.

edge_faces

Identify the faces connected to a given edge.

edge_loop

Identify the parent loops of the a given edge.

fillet

Fillet the edges of the Brep.

filleted

Construct a filleted copy of the Brep.

fix

Fix the shell.

from_brepfaces

Make a Brep from a list of Brep faces forming an open or closed shell.

from_breps

Construct one compound Brep from a list of other Breps.

from_cone

Construct a Brep from a COMPAS cone.

from_curves

Construct a Brep from a set of curves.

from_iges

Construct a Brep from the data contained in an IGES file.

from_json

Construct an object of this type from a JSON file.

from_jsonstring

Construct an object of this type from a JSON string.

from_loft

Construct a Brep by lofting a set of curves.

from_pipe

Construct a Brep by extruding a closed curve along a path curve.

from_planes

Construct a Brep from a set of planes.

from_polygons

Construct a Brep from a set of polygons.

from_step

Conctruct a Brep from the data contained in a STEP file.

from_sweep

Construct a BRep by sweeping a profile along a path.

from_torus

Construct a Brep from a COMPAS torus.

heal

Heal the shape.

make_solid

Convert the current shape to a solid if it is a shell.

overlap

Compute the overlap between this BRep and another.

rotate

Rotate the geometry.

rotated

Returns a rotated copy of this geometry.

scale

Scale the geometry.

scaled

Returns a scaled copy of this geometry.

sew

Sew together the individual parts of the shape.

sha256

Compute a hash of the data for comparison during version control using the sha256 algorithm.

to_iges

Write the Brep shape to an IGES file.

to_json

Convert an object to its native data representation and save it to a JSON file.

to_jsonstring

Convert an object to its native data representation and save it to a JSON string.

to_polygons

Convert the faces of this Brep shape to polygons.

to_step

Write the Brep shape to a STEP file.

to_stl

Write the Brep shape to an STL file.

to_tesselation

Create a tesselation of the shape for visualisation.

to_viewmesh

Convert this Brep to a view mesh.

transformed

Returns a transformed copy of this geometry.

translate

Translate the geometry.

translated

Returns a translated copy of this geometry.

validate_data

Validate the data against the object's data schema.

vertex_edges

Identify the edges connected to a given vertex.

vertex_faces

Identify the faces connected to a vertex.

vertex_neighbors

Identify the neighbouring vertices of a given vertex.