r/GraphicsProgramming • • Nov 02 '23

Question deCasteljau Algorithm

Can anyone explain the algorithm? Instructor told about it in the lecture but his teaching is terrible so I still have no clue. Besides explanation do you have any visual material for this?

0 Upvotes

3 comments sorted by

View all comments

11

u/hi_im_new_to_this Nov 02 '23

For Bezier curves? Yeah, it’s not that complicated actually! Basically: if you have three control points and want to find the point at t (where t is between 0 and 1) just lerp t between the control points 1 and 2, then lerp between control points 2 and 3. Now you have two new points, lerp t between them, that’s your answer.

Basically: if you have N control points, lerp between them pairwise to get N-1 new points. Apply recursively until you only have one point left.

This article is a pretty good reference for all things Bezier: https://pomax.github.io/bezierinfo/#decasteljau