If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content

Course: Unlisted resources area > Unit 2

Lesson 1: ProcessingJS documentation

bezier(x1, y1, cx1, cy1, cx2, cy2, x2, y2)

Draws a bezier curve. To extract points and tangents after drawing the curve, use bezierPoint() and bezierTangent().
Parameters:
NameDescription
x1the x-coordinate of the first endpoint
y1the y-coordinate of the first endpoint
cx1the x-coordinate of the first control point
cy1the y-coordinate of the first control point
cx2the x-coordinate of the second control point
cy2the y-coordinate of the second control point
x2the x-coordinate of the second endpoint
y2the y-coordinate of the second endpoint
Trying to use bezier() to draw a shape? Check out this draggable bezier curve.

Want to join the conversation?

No posts yet.