Mesh¶

compute_rhino3d.Mesh.
CreateFromPlane
(plane, xInterval, yInterval, xCount, yCount, multiple=False)¶ Constructs a planar mesh grid.
Parameters:  plane (rhino3dm.Plane) – Plane of mesh.
 xInterval (rhino3dm.Interval) – Interval describing size and extends of mesh along plane xdirection.
 yInterval (rhino3dm.Interval) – Interval describing size and extends of mesh along plane ydirection.
 xCount (int) – Number of faces in xdirection.
 yCount (int) – Number of faces in ydirection.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromBox
(box, xCount, yCount, zCount, multiple=False)¶ Constructs new mesh that matches a bounding box.
Parameters:  box (rhino3dm.BoundingBox) – A box to use for creation.
 xCount (int) – Number of faces in xdirection.
 yCount (int) – Number of faces in ydirection.
 zCount (int) – Number of faces in zdirection.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new brep, or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromBox1
(box, xCount, yCount, zCount, multiple=False)¶ Constructs new mesh that matches an aligned box.
Parameters:  box (rhino3dm.Box) – Box to match.
 xCount (int) – Number of faces in xdirection.
 yCount (int) – Number of faces in ydirection.
 zCount (int) – Number of faces in zdirection.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromBox2
(corners, xCount, yCount, zCount, multiple=False)¶ Constructs new mesh from 8 corner points.
Parameters:  corners (list[rhino3dm.Point3d]) – 8 points defining the box corners arranged as the vN labels indicate. v7_____________v6 \ \  \ \ _____________\ v4  v5      v3———v2        v0_____________v1
 xCount (int) – Number of faces in xdirection.
 yCount (int) – Number of faces in ydirection.
 zCount (int) – Number of faces in zdirection.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new brep, or None on failure. A new box mesh, on None on error.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromSphere
(sphere, xCount, yCount, multiple=False)¶ Constructs a mesh sphere.
Parameters:  sphere (rhino3dm.Sphere) – Base sphere for mesh.
 xCount (int) – Number of faces in the around direction.
 yCount (int) – Number of faces in the toptobottom direction.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateIcoSphere
(sphere, subdivisions, multiple=False)¶ Constructs a icospherical mesh. A mesh icosphere differs from a standard UV mesh sphere in that it’s vertices are evenly distributed. A mesh icosphere starts from an icosahedron (a regular polyhedron with 20 equilateral triangles). It is then refined by splitting each triangle into 4 smaller triangles. This splitting can be done several times.
Parameters:  sphere (rhino3dm.Sphere) – The input sphere provides the orienting plane and radius.
 subdivisions (int) – The number of times you want the faces split, where 0 <= subdivisions <= 7. Note, the total number of mesh faces produces is: 20 * (4 ^ subdivisions)
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A welded mesh icosphere if successful, or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateQuadSphere
(sphere, subdivisions, multiple=False)¶ Constructs a quad mesh sphere. A quad mesh sphere differs from a standard UV mesh sphere in that it’s vertices are evenly distributed. A quad mesh sphere starts from a cube (a regular polyhedron with 6 square sides). It is then refined by splitting each quad into 4 smaller quads. This splitting can be done several times.
Parameters:  sphere (rhino3dm.Sphere) – The input sphere provides the orienting plane and radius.
 subdivisions (int) – The number of times you want the faces split, where 0 <= subdivisions <= 8. Note, the total number of mesh faces produces is: 6 * (4 ^ subdivisions)
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A welded quad mesh sphere if successful, or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromCylinder
(cylinder, vertical, around, multiple=False)¶ Constructs a mesh cylinder
Parameters:  vertical (int) – Number of faces in the toptobottom direction
 around (int) – Number of faces around the cylinder
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromCone
(cone, vertical, around, multiple=False)¶ Constructs a solid mesh cone.
Parameters:  vertical (int) – Number of faces in the toptobottom direction.
 around (int) – Number of faces around the cone.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A valid mesh if successful.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromCone1
(cone, vertical, around, solid, multiple=False)¶ Constructs a mesh cone.
Parameters:  vertical (int) – Number of faces in the toptobottom direction.
 around (int) – Number of faces around the cone.
 solid (bool) – If False the mesh will be open with no faces on the circular planar portion.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A valid mesh if successful.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromPlanarBoundary
(boundary, parameters, multiple=False)¶ Do not use this overload. Use version that takes a tolerance parameter instead.
Parameters:  boundary (rhino3dm.Curve) – Do not use.
 parameters (rhino3dm.MeshingParameters) – Do not use.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Do not use.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromPlanarBoundary1
(boundary, parameters, tolerance, multiple=False)¶ Attempts to construct a mesh from a closed planar curve.RhinoMakePlanarMeshes
Parameters:  boundary (rhino3dm.Curve) – must be a closed planar curve.
 parameters (rhino3dm.MeshingParameters) – parameters used for creating the mesh.
 tolerance (float) – Tolerance to use during operation.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: New mesh on success or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromClosedPolyline
(polyline, multiple=False)¶ Attempts to create a Mesh that is a triangulation of a closed polyline.
Parameters:  polyline (rhino3dm.Polyline) – must be closed
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: New mesh on success or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromTessellation
(points, edges, plane, allowNewVertices, multiple=False)¶ Attempts to create a mesh that is a triangulation of a list of points, projected on a plane, including its holes and fixed edges.
Parameters:  points (list[rhino3dm.Point3d]) – A list, an array or any enumerable of points.
 plane (rhino3dm.Plane) – A plane.
 allowNewVertices (bool) – If true, the mesh might have more vertices than the list of input points, if doing so will improve long thin triangles.
 edges (IEnumerable<IEnumerable<Point3d>>) – A list of polylines, or other lists of points representing edges. This can be null. If nested enumerable items are null, they will be discarded.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh, or None if not successful.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromBrep
(brep, multiple=False)¶ Constructs a mesh from a brep.
Parameters:  brep (rhino3dm.Brep) – Brep to approximate.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of meshes.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
CreateFromBrep1
(brep, meshingParameters, multiple=False)¶ Constructs a mesh from a brep.
Parameters:  brep (rhino3dm.Brep) – Brep to approximate.
 meshingParameters (rhino3dm.MeshingParameters) – Parameters to use during meshing.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of meshes.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
CreateFromSurface
(surface, multiple=False)¶ Constructs a mesh from a surface
Parameters:  surface (rhino3dm.Surface) – Surface to approximate
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: New mesh representing the surface
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateFromSurface1
(surface, meshingParameters, multiple=False)¶ Constructs a mesh from a surface
Parameters:  surface (rhino3dm.Surface) – Surface to approximate
 meshingParameters (rhino3dm.MeshingParameters) – settings used to create the mesh
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: New mesh representing the surface
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreatePatch
(outerBoundary, angleToleranceRadians, pullbackSurface, innerBoundaryCurves, innerBothSideCurves, innerPoints, trimback, divisions, multiple=False)¶ Construct a mesh patch from a variety of input geometry.
Parameters:  outerBoundary (rhino3dm.Polyline) – (optional: can be null) Outer boundary polyline, if provided this will become the outer boundary of the resulting mesh. Any of the input that is completely outside the outer boundary will be ignored and have no impact on the result. If any of the input intersects the outer boundary the result will be unpredictable and is likely to not include the entire outer boundary.
 angleToleranceRadians (float) – Maximum angle between unit tangents and adjacent verticies. Used to divide curve inputs that cannot otherwise be represented as a polyline.
 innerBoundaryCurves (list[rhino3dm.Curve]) – (optional: can be null) Polylines to create holes in the output mesh. If innerBoundaryCurves are the only input then the result may be null if trimback is set to False (see comments for trimback) because the resulting mesh could be invalid (all faces created contained vertexes from the perimeter boundary).
 pullbackSurface (rhino3dm.Surface) – (optional: can be null) Initial surface where 3d input will be pulled to make a 2d representation used by the function that generates the mesh. Providing a pullbackSurface can be helpful when it is similar in shape to the pattern of the input, the pulled 2d points will be a better representation of the 3d points. If all of the input is more or less coplanar to start with, providing pullbackSurface has no real benefit.
 innerBothSideCurves (list[rhino3dm.Curve]) – (optional: can be null) These polylines will create faces on both sides of the edge. If there are only input points(innerPoints) there is no way to guarantee a triangulation that will create an edge between two particular points. Adding a line, or polyline, to innerBothsideCurves that includes points from innerPoints will help guide the triangulation.
 innerPoints (list[rhino3dm.Point3d]) – (optional: can be null) Points to be used to generate the mesh. If outerBoundary is not null, points outside of that boundary after it has been pulled to pullbackSurface (or the best plane through the input if pullbackSurface is null) will be ignored.
 trimback (bool) – Only used when a outerBoundary has not been provided. When that is the case, the function uses the perimeter of the surface as the outer boundary instead. If true, any face of the resulting triangulated mesh that contains a vertex of the perimeter boundary will be removed.
 divisions (int) – Only used when a outerBoundary has not been provided. When that is the case, division becomes the number of divisions each side of the surface’s perimeter will be divided into to create an outer boundary to work with.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: mesh on success; None on failure
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CreateBooleanUnion
(meshes, multiple=False)¶ Computes the solid union of a set of meshes.
Parameters:  meshes (list[rhino3dm.Mesh]) – Meshes to union.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of Mesh results or None on failure.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
CreateBooleanDifference
(firstSet, secondSet, multiple=False)¶ Computes the solid difference of two sets of Meshes.
Parameters:  firstSet (list[rhino3dm.Mesh]) – First set of Meshes (the set to subtract from).
 secondSet (list[rhino3dm.Mesh]) – Second set of Meshes (the set to subtract).
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of Mesh results or None on failure.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
CreateBooleanIntersection
(firstSet, secondSet, multiple=False)¶ Computes the solid intersection of two sets of meshes.
Parameters:  firstSet (list[rhino3dm.Mesh]) – First set of Meshes.
 secondSet (list[rhino3dm.Mesh]) – Second set of Meshes.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of Mesh results or None on failure.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
CreateBooleanSplit
(meshesToSplit, meshSplitters, multiple=False)¶ Splits a set of meshes with another set.
Parameters:  meshesToSplit (list[rhino3dm.Mesh]) – A list, an array, or any enumerable set of meshes to be split. If this is null, None will be returned.
 meshSplitters (list[rhino3dm.Mesh]) – A list, an array, or any enumerable set of meshes that cut. If this is null, None will be returned.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh array, or None on error.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
CreateFromCurvePipe
(curve, radius, segments, accuracy, capType, faceted, intervals, multiple=False)¶ Constructs a new mesh pipe from a curve.
Parameters:  curve (rhino3dm.Curve) – A curve to pipe.
 radius (float) – The radius of the pipe.
 segments (int) – The number of segments in the pipe.
 accuracy (int) – The accuracy of the pipe.
 capType (MeshPipeCapStyle) – The type of cap to be created at the end of the pipe.
 faceted (bool) – Specifies whether the pipe is faceted, or not.
 intervals (list[rhino3dm.Interval]) – A series of intervals to pipe. This value can be null.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh, or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
Volume
(thisMesh, multiple=False)¶ Compute volume of the mesh.
Parameters: multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed Returns: Volume of the mesh. Return type: float

compute_rhino3d.Mesh.
Smooth
(thisMesh, smoothFactor, bXSmooth, bYSmooth, bZSmooth, bFixBoundaries, coordinateSystem, multiple=False)¶ Smooths a mesh by averaging the positions of mesh vertices in a specified region.
Parameters:  smoothFactor (float) – The smoothing factor, which controls how much vertices move towards the average of the neighboring vertices.
 bXSmooth (bool) – When True vertices move in X axis direction.
 bYSmooth (bool) – When True vertices move in Y axis direction.
 bZSmooth (bool) – When True vertices move in Z axis direction.
 bFixBoundaries (bool) – When True vertices along naked edges will not be modified.
 coordinateSystem (SmoothingCoordinateSystem) – The coordinates to determine the direction of the smoothing.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if successful, False otherwise.
Return type: bool

compute_rhino3d.Mesh.
Smooth1
(thisMesh, smoothFactor, bXSmooth, bYSmooth, bZSmooth, bFixBoundaries, coordinateSystem, plane, multiple=False)¶ Smooths a mesh by averaging the positions of mesh vertices in a specified region.
Parameters:  smoothFactor (float) – The smoothing factor, which controls how much vertices move towards the average of the neighboring vertices.
 bXSmooth (bool) – When True vertices move in X axis direction.
 bYSmooth (bool) – When True vertices move in Y axis direction.
 bZSmooth (bool) – When True vertices move in Z axis direction.
 bFixBoundaries (bool) – When True vertices along naked edges will not be modified.
 coordinateSystem (SmoothingCoordinateSystem) – The coordinates to determine the direction of the smoothing.
 plane (rhino3dm.Plane) – If SmoothingCoordinateSystem.CPlane specified, then the construction plane.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if successful, False otherwise.
Return type: bool

compute_rhino3d.Mesh.
Smooth2
(thisMesh, vertexIndices, smoothFactor, bXSmooth, bYSmooth, bZSmooth, bFixBoundaries, coordinateSystem, plane, multiple=False)¶ Smooths part of a mesh by averaging the positions of mesh vertices in a specified region.
Parameters:  vertexIndices (list[int]) – The mesh vertex indices that specify the part of the mesh to smooth.
 smoothFactor (float) – The smoothing factor, which controls how much vertices move towards the average of the neighboring vertices.
 bXSmooth (bool) – When True vertices move in X axis direction.
 bYSmooth (bool) – When True vertices move in Y axis direction.
 bZSmooth (bool) – When True vertices move in Z axis direction.
 bFixBoundaries (bool) – When True vertices along naked edges will not be modified.
 coordinateSystem (SmoothingCoordinateSystem) – The coordinates to determine the direction of the smoothing.
 plane (rhino3dm.Plane) – If SmoothingCoordinateSystem.CPlane specified, then the construction plane.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if successful, False otherwise.
Return type: bool

compute_rhino3d.Mesh.
Unweld
(thisMesh, angleToleranceRadians, modifyNormals, multiple=False)¶ Makes sure that faces sharing an edge and having a difference of normal greater than or equal to angleToleranceRadians have unique vertexes along that edge, adding vertices if necessary.
Parameters:  angleToleranceRadians (float) – Angle at which to make unique vertices.
 modifyNormals (bool) – Determines whether new vertex normals will have the same vertex normal as the original (false) or vertex normals made from the corrsponding face normals (true)
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Return type: void

compute_rhino3d.Mesh.
UnweldEdge
(thisMesh, edgeIndices, modifyNormals, multiple=False)¶ Adds creases to a smooth mesh by creating coincident vertices along selected edges.
Parameters:  edgeIndices (list[int]) – An array of mesh topology edge indices.
 modifyNormals (bool) – If true, the vertex normals on each side of the edge take the same value as the face to which they belong, giving the mesh a hard edge look. If false, each of the vertex normals on either side of the edge is assigned the same value as the original normal that the pair is replacing, keeping a smooth look.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if successful, False otherwise.
Return type: bool

compute_rhino3d.Mesh.
Weld
(thisMesh, angleToleranceRadians, multiple=False)¶ Makes sure that faces sharing an edge and having a difference of normal greater than or equal to angleToleranceRadians share vertexes along that edge, vertex normals are averaged.
Parameters:  angleToleranceRadians (float) – Angle at which to weld vertices.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Return type: void

compute_rhino3d.Mesh.
RebuildNormals
(thisMesh, multiple=False)¶ Removes mesh normals and reconstructs the face and vertex normals based on the orientation of the faces.
Parameters: multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed Return type: void

compute_rhino3d.Mesh.
ExtractNonManifoldEdges
(thisMesh, selective, multiple=False)¶ Extracts, or removes, nonmanifold mesh edges.
Parameters:  selective (bool) – If true, then extract hanging faces only.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A mesh containing the extracted nonmanifold parts if successful, None otherwise.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
HealNakedEdges
(thisMesh, distance, multiple=False)¶ Attempts to “heal” naked edges in a mesh based on a given distance. First attempts to move vertexes to neighboring vertexes that are within that distance away. Then it finds edges that have a closest point to the vertex within the distance and splits the edge. When it finds one it splits the edge and makes two new edges using that point.
Parameters:  distance (float) – Distance to not exceed when modifying the mesh.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if successful, False otherwise.
Return type: bool

compute_rhino3d.Mesh.
FillHoles
(thisMesh, multiple=False)¶ Attempts to determine “holes” in the mesh by chaining naked edges together. Then it triangulates the closed polygons adds the faces to the mesh.
Parameters: multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed Returns: True if successful, False otherwise. Return type: bool

compute_rhino3d.Mesh.
FileHole
(thisMesh, topologyEdgeIndex, multiple=False)¶ Given a starting “naked” edge index, this function attempts to determine a “hole” by chaining additional naked edges together until if returns to the start index. Then it triangulates the closed polygon and either adds the faces to the mesh.
Parameters:  topologyEdgeIndex (int) – Starting naked edge index.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if successful, False otherwise.
Return type: bool

compute_rhino3d.Mesh.
UnifyNormals
(thisMesh, multiple=False)¶ Attempts to fix inconsistencies in the directions of mesh faces in a mesh. This function does not modify mesh vertex normals, it rearranges the mesh face winding and face normals to make them all consistent. Note, you may want to call Mesh.Normals.ComputeNormals() to recompute vertex normals after calling this functions.
Parameters: multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed Returns: number of faces that were modified. Return type: int

compute_rhino3d.Mesh.
UnifyNormals1
(thisMesh, countOnly, multiple=False)¶ Attempts to fix inconsistencies in the directions of mesh faces in a mesh. This function does not modify mesh vertex normals, it rearranges the mesh face winding and face normals to make them all consistent. Note, you may want to call Mesh.Normals.ComputeNormals() to recompute vertex normals after calling this functions.
Parameters:  countOnly (bool) – If true, then only the number of faces that would be modified is determined.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: If countOnly=false, the number of faces that were modified. If countOnly=true, the number of faces that would be modified.
Return type: int

compute_rhino3d.Mesh.
SplitDisjointPieces
(thisMesh, multiple=False)¶ Splits up the mesh into its unconnected pieces.
Parameters: multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed Returns: An array containing all the disjoint pieces that make up this Mesh. Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
Split
(thisMesh, plane, multiple=False)¶ Split a mesh by an infinite plane.
Parameters:  plane (rhino3dm.Plane) – The splitting plane.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh array with the split result. This can be None if no result was found.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
Split1
(thisMesh, mesh, multiple=False)¶ Split a mesh with another mesh.
Parameters:  mesh (rhino3dm.Mesh) – Mesh to split with.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of mesh segments representing the split result.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
Split2
(thisMesh, meshes, multiple=False)¶ Split a mesh with a collection of meshes.
Parameters:  meshes (list[rhino3dm.Mesh]) – Meshes to split with.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of mesh segments representing the split result.
Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
GetOutlines
(thisMesh, plane, multiple=False)¶ Constructs the outlines of a mesh projected against a plane.
Parameters:  plane (rhino3dm.Plane) – A plane to project against.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of polylines, or None on error.
Return type: rhino3dm.Polyline[]

compute_rhino3d.Mesh.
GetOutlines1
(thisMesh, viewport, multiple=False)¶ Constructs the outlines of a mesh. The projection information in the viewport is used to determine how the outlines are projected.
Parameters:  viewport (Display.RhinoViewport) – A viewport to determine projection direction.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of polylines, or None on error.
Return type: rhino3dm.Polyline[]

compute_rhino3d.Mesh.
GetOutlines2
(thisMesh, viewportInfo, plane, multiple=False)¶ Constructs the outlines of a mesh.
Parameters:  viewportInfo (ViewportInfo) – The viewport info that provides the outline direction.
 plane (rhino3dm.Plane) – Usually the view’s construction plane. If a parallel projection and view plane is parallel to this, then project the results to the plane.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of polylines, or None on error.
Return type: rhino3dm.Polyline[]

compute_rhino3d.Mesh.
GetNakedEdges
(thisMesh, multiple=False)¶ Returns all edges of a mesh that are considered “naked” in the sense that the edge only has one face.
Parameters: multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed Returns: An array of polylines, or None on error. Return type: rhino3dm.Polyline[]

compute_rhino3d.Mesh.
ExplodeAtUnweldedEdges
(thisMesh, multiple=False)¶ Explode the mesh into submeshes where a submesh is a collection of faces that are contained within a closed loop of “unwelded” edges. Unwelded edges are edges where the faces that share the edge have unique mesh vertexes (not mesh topology vertexes) at both ends of the edge.
Parameters: multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed Returns: Array of submeshes on success; None on error. If the count in the returned array is 1, then nothing happened and the ouput is essentially a copy of the input. Return type: rhino3dm.Mesh[]

compute_rhino3d.Mesh.
ClosestPoint
(thisMesh, testPoint, multiple=False)¶ Gets the point on the mesh that is closest to a given test point.
Parameters:  testPoint (rhino3dm.Point3d) – Point to seach for.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: The point on the mesh closest to testPoint, or Point3d.Unset on failure.
Return type: rhino3dm.Point3d

compute_rhino3d.Mesh.
ClosestMeshPoint
(thisMesh, testPoint, maximumDistance, multiple=False)¶ Gets the point on the mesh that is closest to a given test point. Similar to the ClosestPoint function except this returns a MeshPoint class which includes extra information beyond just the location of the closest point.
Parameters:  testPoint (rhino3dm.Point3d) – The source of the search.
 maximumDistance (float) – Optional upper bound on the distance from test point to the mesh. If you are only interested in finding a point Q on the mesh when testPoint.DistanceTo(Q) < maximumDistance, then set maximumDistance to that value. This parameter is ignored if you pass 0.0 for a maximumDistance.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: closest point information on success. None on failure.
Return type: MeshPoint

compute_rhino3d.Mesh.
ClosestPoint1
(thisMesh, testPoint, maximumDistance, multiple=False)¶ Gets the point on the mesh that is closest to a given test point.
Parameters:  testPoint (rhino3dm.Point3d) – Point to seach for.
 maximumDistance (float) – Optional upper bound on the distance from test point to the mesh. If you are only interested in finding a point Q on the mesh when testPoint.DistanceTo(Q) < maximumDistance, then set maximumDistance to that value. This parameter is ignored if you pass 0.0 for a maximumDistance.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Index of face that the closest point lies on if successful. 1 if not successful; the value of pointOnMesh is undefined.
Return type: int

compute_rhino3d.Mesh.
ClosestPoint2
(thisMesh, testPoint, maximumDistance, multiple=False)¶ Gets the point on the mesh that is closest to a given test point.
Parameters:  testPoint (rhino3dm.Point3d) – Point to seach for.
 maximumDistance (float) – Optional upper bound on the distance from test point to the mesh. If you are only interested in finding a point Q on the mesh when testPoint.DistanceTo(Q) < maximumDistance, then set maximumDistance to that value. This parameter is ignored if you pass 0.0 for a maximumDistance.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Index of face that the closest point lies on if successful. 1 if not successful; the value of pointOnMesh is undefined.
Return type: int

compute_rhino3d.Mesh.
PointAt
(thisMesh, meshPoint, multiple=False)¶ Evaluate a mesh at a set of barycentric coordinates.
Parameters:  meshPoint (MeshPoint) – MeshPoint instance contiaining a valid Face Index and Barycentric coordinates.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A Point on the mesh or Point3d.Unset if the faceIndex is not valid or if the barycentric coordinates could not be evaluated.
Return type: rhino3dm.Point3d

compute_rhino3d.Mesh.
PointAt1
(thisMesh, faceIndex, t0, t1, t2, t3, multiple=False)¶ Evaluates a mesh at a set of barycentric coordinates. Barycentric coordinates must be assigned in accordance with the rules as defined by MeshPoint.T.
Parameters:  faceIndex (int) – Index of triangle or quad to evaluate.
 t0 (float) – First barycentric coordinate.
 t1 (float) – Second barycentric coordinate.
 t2 (float) – Third barycentric coordinate.
 t3 (float) – Fourth barycentric coordinate. If the face is a triangle, this coordinate will be ignored.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A Point on the mesh or Point3d.Unset if the faceIndex is not valid or if the barycentric coordinates could not be evaluated.
Return type: rhino3dm.Point3d

compute_rhino3d.Mesh.
NormalAt
(thisMesh, meshPoint, multiple=False)¶ Evaluate a mesh normal at a set of barycentric coordinates.
Parameters:  meshPoint (MeshPoint) – MeshPoint instance contiaining a valid Face Index and Barycentric coordinates.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A Normal vector to the mesh or Vector3d.Unset if the faceIndex is not valid or if the barycentric coordinates could not be evaluated.
Return type: rhino3dm.Vector3d

compute_rhino3d.Mesh.
NormalAt1
(thisMesh, faceIndex, t0, t1, t2, t3, multiple=False)¶ Evaluate a mesh normal at a set of barycentric coordinates. Barycentric coordinates must be assigned in accordance with the rules as defined by MeshPoint.T.
Parameters:  faceIndex (int) – Index of triangle or quad to evaluate.
 t0 (float) – First barycentric coordinate.
 t1 (float) – Second barycentric coordinate.
 t2 (float) – Third barycentric coordinate.
 t3 (float) – Fourth barycentric coordinate. If the face is a triangle, this coordinate will be ignored.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A Normal vector to the mesh or Vector3d.Unset if the faceIndex is not valid or if the barycentric coordinates could not be evaluated.
Return type: rhino3dm.Vector3d

compute_rhino3d.Mesh.
ColorAt
(thisMesh, meshPoint, multiple=False)¶ Evaluate a mesh color at a set of barycentric coordinates.
Parameters:  meshPoint (MeshPoint) – MeshPoint instance contiaining a valid Face Index and Barycentric coordinates.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: The interpolated vertex color on the mesh or Color.Transparent if the faceIndex is not valid, if the barycentric coordinates could not be evaluated, or if there are no colors defined on the mesh.
Return type: Color

compute_rhino3d.Mesh.
ColorAt1
(thisMesh, faceIndex, t0, t1, t2, t3, multiple=False)¶ Evaluate a mesh normal at a set of barycentric coordinates. Barycentric coordinates must be assigned in accordance with the rules as defined by MeshPoint.T.
Parameters:  faceIndex (int) – Index of triangle or quad to evaluate.
 t0 (float) – First barycentric coordinate.
 t1 (float) – Second barycentric coordinate.
 t2 (float) – Third barycentric coordinate.
 t3 (float) – Fourth barycentric coordinate. If the face is a triangle, this coordinate will be ignored.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: The interpolated vertex color on the mesh or Color.Transparent if the faceIndex is not valid, if the barycentric coordinates could not be evaluated, or if there are no colors defined on the mesh.
Return type: Color

compute_rhino3d.Mesh.
PullPointsToMesh
(thisMesh, points, multiple=False)¶ Pulls a collection of points to a mesh.
Parameters:  points (list[rhino3dm.Point3d]) – An array, a list or any enumerable set of points.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of points. This can be empty.
Return type: rhino3dm.Point3d[]

compute_rhino3d.Mesh.
Offset
(thisMesh, distance, multiple=False)¶ Makes a new mesh with vertices offset a distance in the opposite direction of the existing vertex normals. Same as Mesh.Offset(distance, false)
Parameters:  distance (float) – A distance value to use for offsetting.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh on success, or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
Offset1
(thisMesh, distance, solidify, multiple=False)¶ Makes a new mesh with vertices offset a distance in the opposite direction of the existing vertex normals. Optionally, based on the value of solidify, adds the input mesh and a ribbon of faces along any naked edges. If solidify is False it acts exactly as the Offset(distance) function.
Parameters:  distance (float) – A distance value.
 solidify (bool) – True if the mesh should be solidified.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh on success, or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
Offset2
(thisMesh, distance, solidify, direction, multiple=False)¶ Makes a new mesh with vertices offset a distance along the direction parameter. Optionally, based on the value of solidify, adds the input mesh and a ribbon of faces along any naked edges. If solidify is False it acts exactly as the Offset(distance) function.
Parameters:  distance (float) – A distance value.
 solidify (bool) – True if the mesh should be solidified.
 direction (rhino3dm.Vector3d) – Direction of offset for all vertices.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh on success, or None on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
CollapseFacesByEdgeLength
(thisMesh, bGreaterThan, edgeLength, multiple=False)¶ Collapses multiple mesh faces, with greater/less than edge length, based on the principles found in Stan Melax’s mesh reduction PDF, see http://pomax.nihongoresources.com/downloads/PolygonReduction.pdf
Parameters:  bGreaterThan (bool) – Determines whether edge with lengths greater than or less than edgeLength are collapsed.
 edgeLength (float) – Length with which to compare to edge lengths.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Number of edges (faces) that were collapsed.
Return type: int

compute_rhino3d.Mesh.
CollapseFacesByArea
(thisMesh, lessThanArea, greaterThanArea, multiple=False)¶ Collapses multiple mesh faces, with areas less than LessThanArea and greater than GreaterThanArea, based on the principles found in Stan Melax’s mesh reduction PDF, see http://pomax.nihongoresources.com/downloads/PolygonReduction.pdf
Parameters:  lessThanArea (float) – Area in which faces are selected if their area is less than or equal to.
 greaterThanArea (float) – Area in which faces are selected if their area is greater than or equal to.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Number of faces that were collapsed in the process.
Return type: int

compute_rhino3d.Mesh.
CollapseFacesByByAspectRatio
(thisMesh, aspectRatio, multiple=False)¶ Collapses a multiple mesh faces, determined by face aspect ratio, based on criteria found in Stan Melax’s polygon reduction, see http://pomax.nihongoresources.com/downloads/PolygonReduction.pdf
Parameters:  aspectRatio (float) – Faces with an aspect ratio less than aspectRatio are considered as candidates.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Number of faces that were collapsed in the process.
Return type: int

compute_rhino3d.Mesh.
GetUnsafeLock
(thisMesh, writable, multiple=False)¶ Allows to obtain unsafe pointers to the underlying unmanaged data structures of the mesh.
Parameters:  writable (bool) – True if user will need to write onto the structure. False otherwise.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A lock that needs to be released.
Return type: MeshUnsafeLock

compute_rhino3d.Mesh.
ReleaseUnsafeLock
(thisMesh, meshData, multiple=False)¶ Updates the Mesh data with the information that was stored via the .
Parameters:  meshData (MeshUnsafeLock) – The data that will be unlocked.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Return type: void

compute_rhino3d.Mesh.
WithShutLining
(thisMesh, faceted, tolerance, curves, multiple=False)¶ Constructs new mesh from the current one, with shut lining applied to it.
Parameters:  faceted (bool) – Specifies whether the shutline is faceted.
 tolerance (float) – The tolerance of the shutline.
 curves (IEnumerable<ShutLiningCurveInfo>) – A collection of curve arguments.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh with shutlining. Null on failure.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
WithDisplacement
(thisMesh, displacement, multiple=False)¶ Constructs new mesh from the current one, with displacement applied to it.
Parameters:  displacement (MeshDisplacementInfo) – Information on mesh displacement.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh with shutlining.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
WithEdgeSoftening
(thisMesh, softeningRadius, chamfer, faceted, force, angleThreshold, multiple=False)¶ Constructs new mesh from the current one, with edge softening applied to it.
Parameters:  softeningRadius (float) – The softening radius.
 chamfer (bool) – Specifies whether to chamfer the edges.
 faceted (bool) – Specifies whether the edges are faceted.
 force (bool) – Specifies whether to soften edges despite too large a radius.
 angleThreshold (float) – Threshold angle (in degrees) which controls whether an edge is softened or not. The angle refers to the angles between the adjacent faces of an edge.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: A new mesh with soft edges.
Return type: rhino3dm.Mesh

compute_rhino3d.Mesh.
Reduce
(thisMesh, desiredPolygonCount, allowDistortion, accuracy, normalizeSize, multiple=False)¶ Reduce polygon count
Parameters:  desiredPolygonCount (int) – desired or target number of faces
 allowDistortion (bool) – If True mesh appearance is not changed even if the target polygon count is not reached
 accuracy (int) – Integer from 1 to 10 telling how accurate reduction algorithm to use. Greater number gives more accurate results
 normalizeSize (bool) – If True mesh is fitted to an axis aligned unit cube until reduction is complete
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if mesh is successfully reduced and False if mesh could not be reduced for some reason.
Return type: bool

compute_rhino3d.Mesh.
Reduce1
(thisMesh, desiredPolygonCount, allowDistortion, accuracy, normalizeSize, cancelToken, progress, multiple=False)¶ Reduce polygon count
Parameters:  desiredPolygonCount (int) – desired or target number of faces
 allowDistortion (bool) – If True mesh appearance is not changed even if the target polygon count is not reached
 accuracy (int) – Integer from 1 to 10 telling how accurate reduction algorithm to use. Greater number gives more accurate results
 normalizeSize (bool) – If True mesh is fitted to an axis aligned unit cube until reduction is complete
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if mesh is successfully reduced and False if mesh could not be reduced for some reason.
Return type: bool

compute_rhino3d.Mesh.
Reduce2
(thisMesh, parameters, multiple=False)¶ Reduce polygon count
Parameters:  parameters (ReduceMeshParameters) – Parameters
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: True if mesh is successfully reduced and False if mesh could not be reduced for some reason.
Return type: bool

compute_rhino3d.Mesh.
ComputeThickness
(meshes, maximumThickness, multiple=False)¶ Compute thickness metrics for this mesh.
Parameters:  meshes (list[rhino3dm.Mesh]) – Meshes to include in thickness analysis.
 maximumThickness (float) – Maximum thickness to consider. Use as small a thickness as possible to speed up the solver.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Array of thickness measurements.
Return type: MeshThicknessMeasurement[]

compute_rhino3d.Mesh.
ComputeThickness1
(meshes, maximumThickness, cancelToken, multiple=False)¶ Compute thickness metrics for this mesh.
Parameters:  meshes (list[rhino3dm.Mesh]) – Meshes to include in thickness analysis.
 maximumThickness (float) – Maximum thickness to consider. Use as small a thickness as possible to speed up the solver.
 cancelToken (System.Threading.CancellationToken) – Computation cancellation token.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Array of thickness measurements.
Return type: MeshThicknessMeasurement[]

compute_rhino3d.Mesh.
ComputeThickness2
(meshes, maximumThickness, sharpAngle, cancelToken, multiple=False)¶ Compute thickness metrics for this mesh.
Parameters:  meshes (list[rhino3dm.Mesh]) – Meshes to include in thickness analysis.
 maximumThickness (float) – Maximum thickness to consider. Use as small a thickness as possible to speed up the solver.
 sharpAngle (float) – Sharpness angle in radians.
 cancelToken (System.Threading.CancellationToken) – Computation cancellation token.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: Array of thickness measurements.
Return type: MeshThicknessMeasurement[]

compute_rhino3d.Mesh.
CreateContourCurves
(meshToContour, contourStart, contourEnd, interval, multiple=False)¶ Constructs contour curves for a mesh, sectioned along a linear axis.
Parameters:  meshToContour (rhino3dm.Mesh) – A mesh to contour.
 contourStart (rhino3dm.Point3d) – A start point of the contouring axis.
 contourEnd (rhino3dm.Point3d) – An end point of the contouring axis.
 interval (float) – An interval distance.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of curves. This array can be empty.
Return type: rhino3dm.Curve[]

compute_rhino3d.Mesh.
CreateContourCurves1
(meshToContour, sectionPlane, multiple=False)¶ Constructs contour curves for a mesh, sectioned at a plane.
Parameters:  meshToContour (rhino3dm.Mesh) – A mesh to contour.
 sectionPlane (rhino3dm.Plane) – A cutting plane.
 multiple (bool) – (default False) If True, all parameters are expected as lists of equal length and input will be batch processed
Returns: An array of curves. This array can be empty.
Return type: rhino3dm.Curve[]