Class: Bezier2D
2D Bezier Curve
Constructors
Accessors
Methods
Constructors
constructor
• new Bezier2D(vec2Ds?
): Bezier2D
instance bezier class
Parameters
Name | Type | Default value |
---|---|---|
vec2Ds | Vector2 [] | [] |
Returns
Defined in
Accessors
points
• get
points(): Vector2
[]
get all bezier 2d points
Returns
Vector2
[]
Defined in
• set
points(value
): void
set bezier 2d point[x,y] list must great 4
Parameters
Name | Type |
---|---|
value | Vector2 [] |
Returns
void
Defined in
Methods
getValue
▸ getValue(v
): Vector2
get point2d at curve
Parameters
Name | Type | Description |
---|---|---|
v | number | 0.0 ~ 1.0 |
Returns
return point2D at curve
Defined in
createBezierPoints
▸ createBezierPoints(anchorpoints
, pointsAmount
): Bezier2D
caclute bezier curve points at line [ 0.0 , 1.0 ]
Parameters
Name | Type | Description |
---|---|---|
anchorpoints | Vector2 [] | bezier anchor |
pointsAmount | number | point count |
Returns
get a bezier curve [Bezier2D]