Rhino C# Extrude a surface to a solid

Hi all,

What is the proper way to create a solid (rhino.geometry.brep) by extruding a rhino.geometry.surface?

I could not find a method that does this. While in the user interface of Rhino extruding a surface
as an operation is available (ExtrudeSrf).


My guess would be that it’s similar to this:

Hi Rayaan,

You may extrude a BrepFace:


Thanks for your reaction.

In the BrepFace.CreateExtrusion a surface is created by extruding a curve.

I am looking for the next step, where you apply thickness to the surface. Possibly by creating a solid by extruding the surface.


Should be this one: https://developer.rhino3d.com/api/RhinoCommon/html/M_Rhino_Geometry_Brep_CreateFromOffsetFace.htm

Well, actually CreateExtrusion extrudes the boundaries of a BrepFace along a curve. You may optionally cap the extruded Breps with the original BrepFace.

An offset always is in the normal directions of the face. If your surface is planar and you always want to “extrude” perpendicular to that plane, then you may use offset like Baris suggested.

Oops, forgot about the direction.