Bezier curves [message #56962] |
Tue, 21 January 2003 16:29  |
Eclipse User |
|
|
|
I think I asked this before, but does GEF/Draw2D have support for
drawing Bezier (quadratic) curves, a la java.awt.geom.GeneralPath.curveTo()?
If not, is it planned?
If not, how would I go about creating a figure that represents a series
of points connected by bezier curves?
--
Colin M Sharples/New Zealand/IBM, IT Architect, IBM Global Services
sharples@nz.ibm.com, t: 64-4-5769853, m: 64-21-402085, f: 64-4-5765616
"Sometimes I think the surest sign intelligent life exists
elsewhere in the Universe is that it's never tried to contact us"
|
|
|
Re: Bezier curves [message #58265 is a reply to message #56962] |
Mon, 27 January 2003 09:24   |
Eclipse User |
|
|
|
Originally posted by: hudsonr.us.i_b_m.com
There is no support for this. It is pretty simple to ask awt.geom package
to generate a shape, and then iterate over that awt shape and create a
Draw2D PointList for a Polyline.
In fact, this is how we draw the focus outline on connections. Select an
object that has connections in the logic example and press Ctrl+'/'.
"Colin Sharples" <sharples@nz1.ibm.com> wrote in message
news:b0kd6h$51m$1@rogue.oti.com...
> I think I asked this before, but does GEF/Draw2D have support for
> drawing Bezier (quadratic) curves, a la
java.awt.geom.GeneralPath.curveTo()?
>
> If not, is it planned?
>
> If not, how would I go about creating a figure that represents a series
> of points connected by bezier curves?
>
> --
> Colin M Sharples/New Zealand/IBM, IT Architect, IBM Global Services
> sharples@nz.ibm.com, t: 64-4-5769853, m: 64-21-402085, f: 64-4-5765616
> "Sometimes I think the surest sign intelligent life exists
> elsewhere in the Universe is that it's never tried to contact us"
>
|
|
|
|
Re: Bezier curves [message #58996 is a reply to message #58406] |
Tue, 28 January 2003 16:12  |
Eclipse User |
|
|
|
Originally posted by: none.us.ibm.com
Curved lines are appoximated with polylines. AWT allows you to set a
"flatness" when appoximating a curve with a polyline. The closer to 0.0,
the more segments that will be used to represent hte curve.
"Colin Sharples" <sharples@nz1.ibm.com> wrote in message
news:b145op$lum$1@rogue.oti.com...
> Randy Hudson wrote:
> > There is no support for this. It is pretty simple to ask awt.geom
package
> > to generate a shape, and then iterate over that awt shape and create a
> > Draw2D PointList for a Polyline.
>
> But that would just draw straight lines between the points, right? How
> would I get curved lines? I assume this can't be done because the
> underlying SWT graphics object doesn't support curveTo().
>
> --
> Colin M Sharples/New Zealand/IBM, IT Architect, IBM Global Services
> sharples@nz.ibm.com, t: 64-4-5769853, m: 64-21-402085, f: 64-4-5765616
> "Sometimes I think the surest sign intelligent life exists
> elsewhere in the Universe is that it's never tried to contact us"
>
|
|
|
Powered by
FUDForum. Page generated in 0.05610 seconds