1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-01-17 22:28:16 +01:00
dotSCAD/docs/lib3x-shape_pie.md

32 lines
1003 B
Markdown
Raw Normal View History

2017-05-08 09:56:23 +08:00
# shape_pie
2017-05-10 16:50:56 +08:00
Returns shape points of a pie (circular sector) shape. They can be used with xxx_extrude modules of dotSCAD. The shape points can be also used with the built-in polygon module.
2017-05-08 09:56:23 +08:00
## Parameters
- `radius` : The radius of the circle.
2017-05-22 09:29:48 +08:00
- `angle` : A single value or a 2 element vector which defines the central angle. The first element of the vector is the beginning angle in degrees, and the second element is the ending angle.
2017-05-08 09:56:23 +08:00
- `$fa`, `$fs`, `$fn` : Check [the circle module](https://en.wikibooks.org/wiki/OpenSCAD_User_Manual/Using_the_2D_Subsystem#circle) for more details.
## Examples
2020-01-28 17:51:20 +08:00
use <shape_pie.scad>;
2017-05-08 09:56:23 +08:00
2017-05-10 16:50:56 +08:00
shape_pts = shape_pie(10, [45, 315], $fn = 24);
polygon(shape_pts);
2017-05-08 09:56:23 +08:00
2021-02-24 21:09:54 +08:00
![shape_pie](images/lib3x-shape_pie-1.JPG)
2017-05-08 09:56:23 +08:00
2020-01-28 17:51:20 +08:00
use <shape_pie.scad>;
use <helix_extrude.scad>;
2017-05-08 10:01:10 +08:00
2017-05-10 16:50:56 +08:00
shape_pts = shape_pie(10, [45, 315], $fn = 8);
2017-05-08 10:01:10 +08:00
2017-05-10 16:50:56 +08:00
helix_extrude(shape_pts,
2017-05-08 10:01:10 +08:00
radius = 40,
levels = 5,
2017-05-10 16:50:56 +08:00
level_dist = 20
2017-05-08 10:01:10 +08:00
);
2017-05-08 09:56:23 +08:00
2021-02-24 21:09:54 +08:00
![shape_pie](images/lib3x-shape_pie-2.JPG)