Method Extrude
Extrude(ProBuilderMesh, IEnumerable<Face>, ExtrudeMethod, float)
Extrudes a collection of faces.
This is the equivalent of the Extrude Faces action.
Declaration
public static Face[] Extrude(this ProBuilderMesh mesh, IEnumerable<Face> faces, ExtrudeMethod method, float distance)
Parameters
Type | Name | Description |
---|---|---|
ProBuilderMesh | mesh | The source mesh. |
IEnumerable<Face> | faces | The faces to extrude. |
ExtrudeMethod | method | Describes how to extrude the faces (separately or as a group, either from averaged or individual normals). |
float | distance | The distance to extrude faces. |
Returns
Type | Description |
---|---|
Face[] | An array of the faces created as a result of the extrusion or null if |
Extrude(ProBuilderMesh, IEnumerable<Edge>, float, bool, bool)
Extrudes a collection of edges.
This is the equivalent of the Extrude Edges action.
Declaration
public static Edge[] Extrude(this ProBuilderMesh mesh, IEnumerable<Edge> edges, float distance, bool extrudeAsGroup, bool enableManifoldExtrude)
Parameters
Type | Name | Description |
---|---|---|
ProBuilderMesh | mesh | The source mesh. |
IEnumerable<Edge> | edges | The edges to extrude. |
float | distance | The distance to extrude. |
bool | extrudeAsGroup | True to keep any shared vertices when extruding adjacent edges; false to split the shared vertex. |
bool | enableManifoldExtrude | True to allow this function to extrude manifold edges; false to disallow. |
Returns
Type | Description |
---|---|
Edge[] | The extruded edges, or null if the action failed due to manifold check or an empty edges parameter. |