OpenSCAD 2D Primitives & Extrusion — PrintPal Docs

OpenSCAD 2D Primitives & Extrusion — PrintPal Docs

2D primitives live in the XY plane and become 3D when you extrude them with linear_extrude (push them up along Z) or rotate_extrude (sweep them around the Z axis to make rotationally-symmetric parts). Most non-boxy real-world parts are cheapest to build this way.

Like sphere , takes r OR d and honors $fn / $fa / $fs . Use $fn=6 for a hexagon, $fn=3 for an equilateral triangle.

A 2D rectangle. size can be a single number (square) or a 2-vector [width, height] .

The escape hatch for any 2D shape you can describe with a list of points.

Generates 2D text using a system or imported font. Becomes 3D when you linear_extrude it.

Parameters: size , font , halign , valign , direction , spacing , language , script .

SVG support is the modern path; many people use SVG so they can author shapes in Inkscape or Figma and extrude them in OpenSCAD.

Push a 2D shape straight up along Z. The flagship 2D→3D operator.

Sweep a 2D shape around the Z axis. The 2D profile must sit entirely on the +X side of the Y axis (no negative X values). Use it for bottles, vases, wheels, pulleys, knobs — anything rotationally symmetric.

Pass angle=120 to sweep only 120°. Combine with rotate to position multiple pie pieces — perfect for blade housings and fan ducts.

Convert a 3D shape back into 2D — useful for generating DXF/SVG drawings from your model.

Grow or shrink a 2D shape. Round corners with r , chamfer with delta + chamfer=true .

Tell the AI agent "bud vase, 60 mm tall, twisted hexagonal profile" and it will pick rotate_extrude or linear_extrude with twist, generate the polygon, and render in seconds.

Recommended articles