Skip to content

Home > @esengine/ecs-framework-monorepo > Interpolation > pathInterpolation

Interpolation.pathInterpolation() method

路径插值(沿着由点组成的路径)

Signature:

typescript
static pathInterpolation(path: Vector2[], t: number, closed?: boolean): Vector2;

Parameters

Parameter

Type

Description

path

Vector2[]

路径点数组

t

number

插值参数 (0-1)

closed

boolean

(Optional) 是否为闭合路径

Returns:

Vector2

路径上的点

基于 MIT 许可证发布