computeElbowDirection Function

Computes the direction vector for an "elbow" for leader based on the attachment point and a frame curve. The elbow direction is determined by whether the attachment point is closer to the left or right side of the frame. If the computed elbow would be tangent to the frame at the intersection, no elbow direction is returned.

computeElbowDirection(attachmentPoint: Point3d, frameCurve: Loop | Path, elbowLength: number): Vector3d | undefined

@returns The direction vector for the elbow, or undefined if the elbow would be tangent to the frame.

Parameter Type Description
attachmentPoint Point3d The point where the leader attaches.
frameCurve Loop | Path The frame curve (either a Loop or Path) to which the leader is attached.
elbowLength number The length of the elbow segment to be created.

Returns - Vector3d | undefined

The direction vector for the elbow, or undefined if the elbow would be tangent to the frame.

Defined in

Last Updated: 29 July, 2025