draw an arc given 3 points in SWT

Posted by Ahmed Kotb on Stack Overflow See other posts from Stack Overflow or by Ahmed Kotb
Published on 2010-05-14T09:39:47Z Indexed on 2010/05/14 9:44 UTC
Read the original article Hit count: 338

Filed under:
|
|

iam using the swt java library and iam having a problem.

the gc draw arc method takes the following arguments GC.drawArc(int x, int y, int width, int height, int startAngle, int endAngle);

but i want to be able to draw the arc using 3 arguments : the source ,destination and control points.

is there any formula to convert between those parameters ?

QuadCurve2D class do exactly what i want but it is not AWT not swt ...and i tried to use java2d under swt but it was very slow ....

any solutions ?

© Stack Overflow or respective owner

Related posts about swt

Related posts about math