OpenSCAD: Difference between revisions
No edit summary |
|||
| Line 2: | Line 2: | ||
==Basic shapes== | ==Basic shapes== | ||
* | * <tt>square</tt> (rectangle), <tt>circle</tt>, <tt>polygon</tt> | ||
* | * <tt>cube</tt> (rectangular prism), <tt>sphere</tt>, <tt>cylinder</tt>, <tt>polyhedron</tt> | ||
<tt>circle</tt> and <tt>cylinder</tt> are approximated using the <tt>fn</tt> system variable. Low values of <tt>fn</tt> can be used to generate regular polygons. A cylinder can have different radii at its top and bottom. A right pentagonal frustrum, for instance, can be generated with <tt>cylinder</tt> using <tt>fn=5</tt>. | <tt>circle</tt> and <tt>cylinder</tt> are approximated using the <tt>fn</tt> system variable. Low values of <tt>fn</tt> can be used to generate regular polygons. A cylinder can have different radii at its top and bottom. A right pentagonal frustrum, for instance, can be generated with <tt>cylinder</tt> using <tt>fn=5</tt>. | ||