Cubic bezier curves

Drawing bezier curves is very easy to do with the flash drawing API. This is accomplished by passing two anchor points and one control point to the curveTo() method of the graphics object. A bezier with two anchor points and one control point is called a quadratic bezier curve.

However, anyone that has been working with bezier curves in Illustrator or the Flash authoring tool is used to have two control points for each curve (or path). A quick search on wikipedia revealed that this is called a cubic bezier curve and demands an algorithm which unfortunately isn’t supported by the drawing API at the moment. Well, it’s just maths, right?

Linked to the wikipedia page was an excellent post by a guy named Paul Tondeur, who had converted the algoritm to Actionscript. With the help of two of these bad boys I created the effect below. Will do some more experimenting and maybe post some code later on.

One Response

  1. Paul Tondeur Says:

    Great work! I really like this effect! I’ve been watching at it a couple of times.
    It will be interesting to see your code later on. Keep up the good work!

Leave a Comment

Please note: Comment moderation is enabled and may delay your comment. There is no need to resubmit your comment.