* make everything in engine a rwlock and cleanup repetitive code 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> * updates 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> * docs Signed-off-by: Jess Frazelle <github@jessfraz.com> --------- Signed-off-by: Jess Frazelle <github@jessfraz.com>
71 lines
322 KiB
Markdown
71 lines
322 KiB
Markdown
---
|
|
title: "startProfileAt"
|
|
excerpt: "Start a new profile at a given point."
|
|
layout: manual
|
|
---
|
|
|
|
Start a new profile at a given point.
|
|
|
|
|
|
|
|
```js
|
|
startProfileAt(to: [number], sketch_surface: SketchSurface, tag?: TagDeclarator) -> Sketch
|
|
```
|
|
|
|
|
|
### Arguments
|
|
|
|
| Name | Type | Description | Required |
|
|
|----------|------|-------------|----------|
|
|
| `to` | `[number]` | | Yes |
|
|
| `sketch_surface` | [`SketchSurface`](/docs/kcl/types/SketchSurface) | A sketch type. | Yes |
|
|
| `tag` | [`TagDeclarator`](/docs/kcl/types#tag-declaration) | | No |
|
|
|
|
### Returns
|
|
|
|
[`Sketch`](/docs/kcl/types/Sketch) - A sketch is a collection of paths.
|
|
|
|
|
|
### Examples
|
|
|
|
```js
|
|
exampleSketch = startSketchOn('XZ')
|
|
|> startProfileAt([0, 0], %)
|
|
|> line(end = [10, 0])
|
|
|> line(end = [0, 10])
|
|
|> line(end = [-10, 0])
|
|
|> close()
|
|
|
|
example = extrude(exampleSketch, length = 5)
|
|
```
|
|
|
|

|
|
|
|
```js
|
|
exampleSketch = startSketchOn('-XZ')
|
|
|> startProfileAt([10, 10], %)
|
|
|> line(end = [10, 0])
|
|
|> line(end = [0, 10])
|
|
|> line(end = [-10, 0])
|
|
|> close()
|
|
|
|
example = extrude(exampleSketch, length = 5)
|
|
```
|
|
|
|

|
|
|
|
```js
|
|
exampleSketch = startSketchOn('-XZ')
|
|
|> startProfileAt([-10, 23], %)
|
|
|> line(end = [10, 0])
|
|
|> line(end = [0, 10])
|
|
|> line(end = [-10, 0])
|
|
|> close()
|
|
|
|
example = extrude(exampleSketch, length = 5)
|
|
```
|
|
|
|

|
|
|
|
|