OpenSCAD User Manual/WIP/Offset Extrude

Offset Extrude
NOTE:  is not available in snapshot builds, but   provides similar functionality and is available in snapshots as of August 2022.

Offset Extrusion is a operation that takes a 2D object as input and generates a 3D object as a result.

The extrusion takes place on the Z axis by first taking an offset of the 3d object, then extruding up/down to that offset.

A slices parameter is also available to increase the resolution of the extrusion, increasing the number of offsets.

See offset for how the offsetting works.

Usage

Parameters

is the height of the extrude. It can be positive or negative.

is the number of slices to make, with an offset at each slice. It must be greater than or equal to 1.

,, and   define the offset function. It works exactly the same as offset.

defines if the extrusion should be centered on the Z-Axis at the current 2d objects height.

Possible Issues

If an offset causes the resulting model to not generate, try increasing the number of. In many cases this will resolve any issues.

If an offset causes a resulting model to self-intersect, the resulting geometry may or may not be manifold.

There are other trivial cases where the resulting model is not valid, in which case using  with scale may be a better solution.