Bezier curve 3

$$$APPLET

Applet Bezier curve . Set a news points with mouse button. Author: Galcik Peter

Applet for handling with Bezier Curves has simple layout and user interface. We can add, move points on canvas by mouse. No action on canvas can be made by keyboard. After every action the curve is redrawn and user can see immediately generated curve. Moreover if we want draw points precisely, we can activate coordinates of intermediate points. Interpolated lines in any point of bezier curve can be showed by moving "Position" slider. And last thing, we can activate animation of curve and set animation speed.

Specification

Applet of Bezier Curve is well designed. Consist of three well structured java files.

  • BezierCurveApplet.java - implements swing layout and event from applet ( + animation Thread).
  • BezierCurveAlgorithm.java - static class implementing DeCasteljau Algorithm.
  • BezierCurve.java - class,that hold all data of bezier curve and implements drawing of curve.

Universal architecture of java files support further development or implementing new features.

 

(c) Galcik Peter 2007