initial commits

master
Charles Iliya Krempeaux 2024-01-15 11:52:43 -08:00
parent c52f1d5889
commit 65aaaf8853
1 changed files with 25 additions and 0 deletions

View File

@ -163,6 +163,31 @@ cylinder(h=50, r1=20, r2=5);
import("3dbenchy.stl") import("3dbenchy.stl")
</pre></code> </pre></code>
</section> </section>
<section>
<h2>Centering</h2>
<p>
By default, a <strong>sphere</strong> is centered at the origin — <code>[0,0,0]</code>.
However, <strong>cuboids</strong>, <strong>cylinders</strong>, <strong>cones</strong>, and <strong>truncated cones</strong> are <em>not</em>, by default, cetered at the origin.
</p>
<p>
To make it so <strong>cuboids</strong>, <strong>cylinders</strong>, <strong>cones</strong>, and <strong>truncated cones</strong> are centered at the origin, use the <code>center=true</code> paramter.
For example:
</p>
<figure>
<pre><code>
cube([50,75,100], center=true);
</code></pre>
</figure>
<p>
And:
</p>
<pre><code>
cylinder(h=50, r1=20, r2=5, center=true);
</code></pre>
<p>
Etc.
</p>
</section>
</article> </article>
</main> </main>
</body> </body>