* updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * start of types docs Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest) * add types files Signed-off-by: Jess Frazelle <github@jessfraz.com> * add links Signed-off-by: Jess Frazelle <github@jessfraz.com> * better Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * uodates Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest) * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> --------- Signed-off-by: Jess Frazelle <github@jessfraz.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
49 lines
58 KiB
Markdown
49 lines
58 KiB
Markdown
---
|
|
title: "patternLinear3d"
|
|
excerpt: "Repeat a 3-dimensional solid along a linear path, with a dynamic amount"
|
|
layout: manual
|
|
---
|
|
|
|
Repeat a 3-dimensional solid along a linear path, with a dynamic amount
|
|
|
|
of distance between each repetition, some specified number of times.
|
|
|
|
```js
|
|
patternLinear3d(data: LinearPattern3dData, extrude_group_set: ExtrudeGroupSet) -> [ExtrudeGroup]
|
|
```
|
|
|
|
|
|
### Arguments
|
|
|
|
| Name | Type | Description | Required |
|
|
|----------|------|-------------|----------|
|
|
| `data` | [`LinearPattern3dData`](kcl/types/LinearPattern3dData) | Data for a linear pattern on a 3D model. | Yes |
|
|
| `extrude_group_set` | [`ExtrudeGroupSet`](kcl/types/ExtrudeGroupSet) | A extrude group or a group of extrude groups. | Yes |
|
|
|
|
### Returns
|
|
|
|
[`[ExtrudeGroup]`](kcl/types/[ExtrudeGroup])
|
|
|
|
|
|
### Examples
|
|
|
|
```js
|
|
const exampleSketch = startSketchOn('XZ')
|
|
|> startProfileAt([0, 0], %)
|
|
|> line([0, 2], %)
|
|
|> line([3, 1], %)
|
|
|> line([0, -4], %)
|
|
|> close(%)
|
|
|
|
const example = extrude(1, exampleSketch)
|
|
|> patternLinear3d({
|
|
axis: [1, 0, 1],
|
|
repetitions: 6,
|
|
distance: 6
|
|
}, %)
|
|
```
|
|
|
|

|
|
|
|
|