1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-09-24 21:41:33 +02:00

update to 3.0

This commit is contained in:
Justin Lin
2021-02-24 21:09:54 +08:00
parent b29753b131
commit e55422c479
450 changed files with 469 additions and 469 deletions

30
docs/lib3x-circle_path.md Normal file
View File

@@ -0,0 +1,30 @@
# circle_path
Sometimes you need all points on the path of a circle. Here's the function. Its `$fa`, `$fs` and `$fn` parameters are consistent with the `circle` module.
## Parameters
- `radius` : The radius of the circle.
- `n` : The number of points you want. It's not greater than the fragments of the circle.
- `$fa`, `$fs`, `$fn` : Check [the circle module](https://en.wikibooks.org/wiki/OpenSCAD_User_Manual/Using_the_2D_Subsystem#circle) for more details.
## Examples
use <circle_path.scad>;
$fn = 24;
points = circle_path(radius = 50);
polygon(points);
leng = len(points);
step_angle = 360 / leng;
for(i = [0:leng - 1]) {
translate(points[i])
rotate([90, 0, 90 + i * step_angle])
linear_extrude(1, center = true)
text("A", valign = "center", halign = "center");
}
![circle_path](images/lib3x-circle_path-1.JPG)