2024-03-13 14:22:22 -07:00
---
title: "angledLineThatIntersects"
excerpt: "Draw an angled line that intersects with a given line."
layout: manual
---
Draw an angled line that intersects with a given line.
2024-03-13 15:43:42 -07:00
```js
2024-06-24 14:45:07 -07:00
angledLineThatIntersects(data: AngledLineThatIntersectsData, sketch_group: SketchGroup, tag?: TagDeclarator) -> SketchGroup
2024-03-13 14:22:22 -07:00
```
### Examples
2024-03-13 15:43:42 -07:00
```js
2024-05-22 09:15:38 -07:00
const exampleSketch = startSketchOn('XZ')
2024-03-13 14:22:22 -07:00
|> startProfileAt([0, 0], %)
2024-05-14 17:10:47 -07:00
|> lineTo([5, 10], %)
2024-06-24 22:39:04 -07:00
|> lineTo([-10, 10], %, $lineToIntersect)
2024-05-14 17:10:47 -07:00
|> lineTo([0, 20], %)
2024-03-13 14:22:22 -07:00
|> angledLineThatIntersects({
2024-05-14 17:10:47 -07:00
angle: 80,
intersectTag: 'lineToIntersect',
offset: 10
}, %)
|> close(%)
const example = extrude(10, exampleSketch)
2024-03-13 14:22:22 -07:00
```
2024-05-23 19:28:13 -07:00

2024-03-13 15:43:42 -07:00
```js
2024-03-13 14:22:22 -07:00
{
// The angle of the line.
angle: number,
// The tag of the line to intersect with.
2024-06-24 14:45:07 -07:00
intersectTag: {
value: string,
},
2024-03-13 14:22:22 -07:00
// The offset from the intersecting line.
offset: number,
}
```
* `sketch_group` : `SketchGroup` - A sketch group is a collection of paths. (REQUIRED)
2024-03-13 15:43:42 -07:00
```js
2024-03-13 14:22:22 -07:00
{
// The id of the sketch group.
id: uuid,
// What the sketch is on (can be a plane or a face).
on: {
// The id of the plane.
id: uuid,
// Origin of the plane.
origin: {
x: number,
y: number,
z: number,
},
type: "plane",
// Type for a plane.
value: "XY" | "XZ" | "YZ" | "Custom",
// What should the plane’ s X axis be?
xAxis: {
x: number,
y: number,
z: number,
},
// What should the plane’ s Y axis be?
yAxis: {
x: number,
y: number,
z: number,
},
// The z-axis (normal).
zAxis: {
x: number,
y: number,
z: number,
},
} |
{
2024-06-23 19:19:24 -07:00
// The extrude group the face is on.
extrudeGroup: {
// The id of the extrusion end cap
endCapId: uuid,
// Chamfers or fillets on this extrude group.
filletOrChamfers: [{
// The engine id of the edge to fillet.
edge_id: uuid,
// The id of the engine command that called this fillet.
id: uuid,
radius: number,
type: "fillet",
} |
{
// The engine id of the edge to chamfer.
edge_id: uuid,
// The id of the engine command that called this chamfer.
id: uuid,
length: number,
2024-06-24 14:45:07 -07:00
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
type: "chamfer",
}],
// The height of the extrude group.
height: number,
// The id of the extrude group.
id: uuid,
// The sketch group.
sketchGroup: {
// The id of the sketch group.
id: uuid,
// What the sketch is on (can be a plane or a face).
on: SketchSurface,
// The starting path.
start: {
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
},
// The paths in the sketch group.
value: [{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "ToPoint",
} |
{
// arc's direction
ccw: string,
// the arc's center
center: [number, number],
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "TangentialArcTo",
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "TangentialArc",
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "Horizontal",
// The x coordinate.
x: number,
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "AngledLineTo",
// The x coordinate.
x: number,
// The y coordinate.
y: number,
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "Base",
}],
},
// The id of the extrusion start cap
startCapId: uuid,
// The extrude surfaces.
value: [{
// The face id for the extrude plane.
faceId: uuid,
// The id of the geometry.
id: uuid,
// The source range.
sourceRange: [number, number],
2024-06-24 14:45:07 -07:00
// The tag.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
type: "extrudePlane",
} |
{
// The face id for the extrude plane.
faceId: uuid,
// The id of the geometry.
id: uuid,
// The source range.
sourceRange: [number, number],
2024-06-24 14:45:07 -07:00
// The tag.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
type: "extrudeArc",
}],
},
2024-03-13 14:22:22 -07:00
// The id of the face.
id: uuid,
type: "face",
// The tag of the face.
value: string,
// What should the face’ s X axis be?
xAxis: {
x: number,
y: number,
z: number,
},
// What should the face’ s Y axis be?
yAxis: {
x: number,
y: number,
z: number,
},
// The z-axis (normal).
zAxis: {
x: number,
y: number,
z: number,
},
},
// The starting path.
start: {
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
},
// The paths in the sketch group.
value: [{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "ToPoint",
} |
{
// arc's direction
ccw: string,
// the arc's center
center: [number, number],
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "TangentialArcTo",
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "TangentialArc",
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "Horizontal",
// The x coordinate.
x: number,
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "AngledLineTo",
// The x coordinate.
x: number,
// The y coordinate.
y: number,
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "Base",
}],
}
```
2024-06-24 14:45:07 -07:00
* `tag` : `TagDeclarator` (OPTIONAL)
```js
{
end: number,
start: number,
value: string,
}
```
2024-03-13 14:22:22 -07:00
### Returns
`SketchGroup` - A sketch group is a collection of paths.
2024-03-13 15:43:42 -07:00
```js
2024-03-13 14:22:22 -07:00
{
// The id of the sketch group.
id: uuid,
// What the sketch is on (can be a plane or a face).
on: {
// The id of the plane.
id: uuid,
// Origin of the plane.
origin: {
x: number,
y: number,
z: number,
},
type: "plane",
// Type for a plane.
value: "XY" | "XZ" | "YZ" | "Custom",
// What should the plane’ s X axis be?
xAxis: {
x: number,
y: number,
z: number,
},
// What should the plane’ s Y axis be?
yAxis: {
x: number,
y: number,
z: number,
},
// The z-axis (normal).
zAxis: {
x: number,
y: number,
z: number,
},
} |
{
2024-06-23 19:19:24 -07:00
// The extrude group the face is on.
extrudeGroup: {
// The id of the extrusion end cap
endCapId: uuid,
// Chamfers or fillets on this extrude group.
filletOrChamfers: [{
// The engine id of the edge to fillet.
edge_id: uuid,
// The id of the engine command that called this fillet.
id: uuid,
radius: number,
type: "fillet",
} |
{
// The engine id of the edge to chamfer.
edge_id: uuid,
// The id of the engine command that called this chamfer.
id: uuid,
length: number,
2024-06-24 14:45:07 -07:00
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
type: "chamfer",
}],
// The height of the extrude group.
height: number,
// The id of the extrude group.
id: uuid,
// The sketch group.
sketchGroup: {
// The id of the sketch group.
id: uuid,
// What the sketch is on (can be a plane or a face).
on: SketchSurface,
// The starting path.
start: {
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
},
// The paths in the sketch group.
value: [{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "ToPoint",
} |
{
// arc's direction
ccw: string,
// the arc's center
center: [number, number],
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "TangentialArcTo",
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "TangentialArc",
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "Horizontal",
// The x coordinate.
x: number,
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "AngledLineTo",
// The x coordinate.
x: number,
// The y coordinate.
y: number,
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
// The to point.
to: [number, number],
type: "Base",
}],
},
// The id of the extrusion start cap
startCapId: uuid,
// The extrude surfaces.
value: [{
// The face id for the extrude plane.
faceId: uuid,
// The id of the geometry.
id: uuid,
// The source range.
sourceRange: [number, number],
2024-06-24 14:45:07 -07:00
// The tag.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
type: "extrudePlane",
} |
{
// The face id for the extrude plane.
faceId: uuid,
// The id of the geometry.
id: uuid,
// The source range.
sourceRange: [number, number],
2024-06-24 14:45:07 -07:00
// The tag.
tag: {
end: number,
start: number,
value: string,
},
2024-06-23 19:19:24 -07:00
type: "extrudeArc",
}],
},
2024-03-13 14:22:22 -07:00
// The id of the face.
id: uuid,
type: "face",
// The tag of the face.
value: string,
// What should the face’ s X axis be?
xAxis: {
x: number,
y: number,
z: number,
},
// What should the face’ s Y axis be?
yAxis: {
x: number,
y: number,
z: number,
},
// The z-axis (normal).
zAxis: {
x: number,
y: number,
z: number,
},
},
// The starting path.
start: {
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
},
// The paths in the sketch group.
value: [{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "ToPoint",
} |
{
// arc's direction
ccw: string,
// the arc's center
center: [number, number],
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "TangentialArcTo",
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "TangentialArc",
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "Horizontal",
// The x coordinate.
x: number,
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "AngledLineTo",
// The x coordinate.
x: number,
// The y coordinate.
y: number,
} |
{
// The from point.
from: [number, number],
2024-06-24 14:45:07 -07:00
// The tag of the path.
tag: {
end: number,
start: number,
value: string,
},
2024-03-13 14:22:22 -07:00
// The to point.
to: [number, number],
type: "Base",
}],
}
```