|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object jfig.objects.FigPolyline jfig.objects.FigBezier
Bezier-style interpolated spline objects.
Class FigBezier represents Bezier-styde splines, either open or closed. It supports all standard FIG line attributes, including arrows.
Part of the code for FigBezier was translated directly from the xfig (version 3.1.3) code of w_intspline.c and u_draw.c. That part of the code is protected by the following copyright conditions: FIG : Facility for Interactive Generation of figures Copyright (c) 1985 by Supoj Sutanthavibul Parts Copyright (c) 1994 by Brian V. Smith Parts Copyright (c) 1991 by Paul King Copyright (c) 1996 by Norman F. Hendrich, Univ. of Hamburg Part of the following code was translated directly from the xfig (version 3.1.3) code of w_intspline.c and u_draw.c. That part of the code is protected by the following copyright conditions: FIG : Facility for Interactive Generation of figures Copyright (c) 1985 by Supoj Sutanthavibul Parts Copyright (c) 1994 by Brian V. Smith Parts Copyright (c) 1991 by Paul King The X Consortium, and any party obtaining a copy of these files from the X Consortium, directly or indirectly, is granted, free of charge, a full and unrestricted irrevocable, world-wide, paid up, royalty-free, nonexclusive right and license to deal in this software and documentation files (the "Software"), including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons who receive copies from any such party to do so, with the only requirement being that this copyright notice remain intact. This license includes without limitation a license to do the foregoing actions under any patents of the party supplying this software to the X Consortium.
Nested Class Summary | |
class |
FigBezier.ControlPoint
ControlPoint: a simple wrapper with double coordinates fields lx, ly, rx, ry. |
Field Summary | |
(package private) double |
_1dSQR2
|
(package private) double |
_2xPI
|
(package private) double |
_SQR2
|
(package private) FigBezier.ControlPoint[] |
cpp
|
(package private) int |
ii
|
(package private) double |
M_PI_2
|
(package private) static java.awt.Point[] |
pp
|
(package private) static int |
PPMAX
|
(package private) double[][] |
stack
|
(package private) int |
stack_p
|
(package private) double |
T
|
(package private) java.awt.Point[] |
wcp_spline
|
(package private) java.awt.Point[] |
wcp1
|
Fields inherited from class jfig.objects.FigPolyline |
attribs, bbox, comment, debug, is_closed, min_i, min_num_points, painter, renderer, selected, showPoints, syncRedrawFlag, trafo, visible, wcp |
Constructor Summary | |
FigBezier(int x0,
int y0,
boolean is_closed,
FigAttribs attribs,
FigTrafo2D trafo)
|
Method Summary | |
FigObject |
copy()
build a copy of this FigPolyline. |
void |
createRenderer()
|
double[] |
getControlPoints()
return a list of double values representing the control points (required for the FIG3.1 file format). |
java.awt.Point[] |
getSplinePoints()
|
void |
rebuild()
rebuild() re-calculates the bezier spline. |
(package private) int |
round(double x)
|
(package private) void |
set_control_point(double x,
double y,
double l1,
double l2,
double theta1,
double theta2,
double t,
FigBezier.ControlPoint cp)
set one control point cp. |
java.lang.String |
toString()
toString() for debug purposes. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
java.awt.Point[] wcp_spline
java.awt.Point[] wcp1
FigBezier.ControlPoint[] cpp
static final int PPMAX
static java.awt.Point[] pp
int ii
double[][] stack
int stack_p
final double T
final double _2xPI
final double _1dSQR2
final double _SQR2
final double M_PI_2
Constructor Detail |
public FigBezier(int x0, int y0, boolean is_closed, FigAttribs attribs, FigTrafo2D trafo)
Method Detail |
public void createRenderer()
createRenderer
in class FigPolyline
final int round(double x)
public double[] getControlPoints()
public java.awt.Point[] getSplinePoints()
public java.lang.String toString()
FigPolyline
toString
in interface FigObject
toString
in class FigPolyline
void set_control_point(double x, double y, double l1, double l2, double theta1, double theta2, double t, FigBezier.ControlPoint cp)
public void rebuild()
rebuild
in interface FigObject
rebuild
in class FigPolyline
public FigObject copy()
copy
in interface FigObject
copy
in class FigPolyline
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |