# Java 2D bezier curves

Alireza Bahmanpour

Greenhorn

Posts: 23

posted 7 years ago

Hi,

I've been told to write the code that allows you to interactively control a bezier curve by dragging the control points in applet.

Now, I can write the code for this to draw a normal cubic curve with the usual two control points, but what I've been told to do is to allow my bezier curve to be longer by allowing it to have more than two control points (4-5). What I believe I have to do is to make another cubic curve, and somehow link the end point of the first bezier curve to the start point of the second bezier curve. But I'm not sure if this is the right thing to do. I would greatly appreciate it if someone could point me in the right direction.

(I wasn't sure if this is the best place to post this, so please accept my appologies if it's not in the right place)

Many thanks

I've been told to write the code that allows you to interactively control a bezier curve by dragging the control points in applet.

Now, I can write the code for this to draw a normal cubic curve with the usual two control points, but what I've been told to do is to allow my bezier curve to be longer by allowing it to have more than two control points (4-5). What I believe I have to do is to make another cubic curve, and somehow link the end point of the first bezier curve to the start point of the second bezier curve. But I'm not sure if this is the right thing to do. I would greatly appreciate it if someone could point me in the right direction.

(I wasn't sure if this is the best place to post this, so please accept my appologies if it's not in the right place)

Many thanks