updates updates updates updates updates updates better updates array of updates updates updates updates Signed-off-by: Jess Frazelle <github@jessfraz.com>
71 lines
323 KiB
Markdown
71 lines
323 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
|
|
const exampleSketch = startSketchOn('XZ')
|
|
|> startProfileAt([0, 0], %)
|
|
|> line([10, 0], %)
|
|
|> line([0, 10], %)
|
|
|> line([-10, 0], %)
|
|
|> close(%)
|
|
|
|
const example = extrude(5, exampleSketch)
|
|
```
|
|
|
|

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

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

|
|
|
|
|