Skip to main content

Function: getSmoothCubicBezierHandlePoints()

getSmoothCubicBezierHandlePoints(anchors): object

Defined in: src/core/VMobjectCurveMath.ts:297

Smooth cubic-Bezier handles for a sequence of anchors (open spline).

Solves the tridiagonal system for a C1-continuous spline through the anchors (the classic "smooth bezier spline" formulation that Manim CE's get_smooth_handle_points computes). For each internal anchor the incoming second handle and outgoing first handle are reflections through the anchor, giving tangent continuity.

Closed paths are smoothed as an open spline over the repeated-endpoint anchor list, so the seam is not periodic-smooth.

Parameters​

anchors​

number[][]

Anchor points (length n+1 for n segments)

Returns​

object

First and second handles, one each per segment (length n)

h1​

h1: number[][]

h2​

h2: number[][]