vispy.geometry.curves module#

vispy.geometry.curves.calc_sq_distance(x1, y1, x2, y2)#
vispy.geometry.curves.curve3_bezier(p1, p2, p3)#

Generate the vertices for a quadratic Bezier curve.

The vertices returned by this function can be passed to a LineVisual or ArrowVisual.

Parameters:
p1array

2D coordinates of the start point

p2array

2D coordinates of the first curve point

p3array

2D coordinates of the end point

Returns:
coordslist

Vertices for the Bezier curve.

See also

curve4_bezier

Notes

For more information about Bezier curves please refer to the Wikipedia page.

vispy.geometry.curves.curve4_bezier(p1, p2, p3, p4)#

Generate the vertices for a third order Bezier curve.

The vertices returned by this function can be passed to a LineVisual or ArrowVisual.

Parameters:
p1array

2D coordinates of the start point

p2array

2D coordinates of the first curve point

p3array

2D coordinates of the second curve point

p4array

2D coordinates of the end point

Returns:
coordslist

Vertices for the Bezier curve.

See also

curve3_bezier

Notes

For more information about Bezier curves please refer to the Wikipedia page.