|
|||||||||
| Home >> All >> java >> awt >> [ geom overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.awt.geom
Class QuadCurve2D.Float

java.lang.Objectjava.awt.geom.QuadCurve2D
java.awt.geom.QuadCurve2D.Float
- All Implemented Interfaces:
- java.lang.Cloneable, java.awt.Shape
- Enclosing class:
- QuadCurve2D
- public static class QuadCurve2D.Float
- extends QuadCurve2D
A two-dimensional curve that is parameterized with a quadratic function and stores coordinate values in single-precision floating-point format.
| Nested Class Summary |
| Nested classes inherited from class java.awt.geom.QuadCurve2D |
QuadCurve2D.Double, QuadCurve2D.Float |
| Field Summary | |
float |
ctrlx
The x coordinate of the curve’s control point. |
float |
ctrly
The y coordinate of the curve’s control point. |
float |
x1
The x coordinate of the curve’s start point. |
float |
x2
The x coordinate of the curve’s end point. |
float |
y1
The y coordinate of the curve’s start point. |
float |
y2
The y coordinate of the curve’s end point. |
| Fields inherited from class java.awt.geom.QuadCurve2D |
|
| Constructor Summary | |
QuadCurve2D.Float()
Constructs a new QuadCurve2D that stores its coordinate values in single-precision floating-point format. |
|
QuadCurve2D.Float(float x1,
float y1,
float cx,
float cy,
float x2,
float y2)
Constructs a new QuadCurve2D that stores its coordinate values in single-precision floating-point format, specifying the initial position of each point. |
|
| Method Summary | |
Rectangle2D |
getBounds2D()
Determines the smallest rectangle that encloses the curve’s start, end and control point. |
Point2D |
getCtrlPt()
Returns the curve’s control point. |
double |
getCtrlX()
Returns the x coordinate of the curve’s control point. |
double |
getCtrlY()
Returns the y coordinate of the curve’s control point. |
Point2D |
getP1()
Returns the curve’s start point. |
Point2D |
getP2()
Returns the curve’s end point. |
double |
getX1()
Returns the x coordinate of the curve’s start point. |
double |
getX2()
Returns the x coordinate of the curve’s end point. |
double |
getY1()
Returns the y coordinate of the curve’s start point. |
double |
getY2()
Returns the y coordinate of the curve’s end point. |
void |
setCurve(double x1,
double y1,
double cx,
double cy,
double x2,
double y2)
Changes the geometry of the curve, specifying coordinate values as double-precision floating-point numbers. |
void |
setCurve(float x1,
float y1,
float cx,
float cy,
float x2,
float y2)
Changes the geometry of the curve, specifying coordinate values as single-precision floating-point numbers. |
| Methods inherited from class java.awt.geom.QuadCurve2D |
clone, contains, contains, contains, contains, getBounds, getFlatness, getFlatness, getFlatness, getFlatnessSq, getFlatnessSq, getFlatnessSq, getPathIterator, getPathIterator, intersects, intersects, setCurve, setCurve, setCurve, setCurve, solveQuadratic, solveQuadratic, subdivide, subdivide, subdivide |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
x1
public float x1
- The x coordinate of the curve’s start point.
y1
public float y1
- The y coordinate of the curve’s start point.
ctrlx
public float ctrlx
- The x coordinate of the curve’s control point.
ctrly
public float ctrly
- The y coordinate of the curve’s control point.
x2
public float x2
- The x coordinate of the curve’s end point.
y2
public float y2
- The y coordinate of the curve’s end point.
| Constructor Detail |
QuadCurve2D.Float
public QuadCurve2D.Float()
- Constructs a new QuadCurve2D that stores its coordinate values
in single-precision floating-point format. All points are
initially at position (0, 0).
QuadCurve2D.Float
public QuadCurve2D.Float(float x1,
float y1,
float cx,
float cy,
float x2,
float y2)
- Constructs a new QuadCurve2D that stores its coordinate values
in single-precision floating-point format, specifying the
initial position of each point.
| Method Detail |
getX1
public double getX1()
- Returns the x coordinate of the curve’s start
point.
- Specified by:
getX1in classQuadCurve2D
getY1
public double getY1()
- Returns the y coordinate of the curve’s start
point.
- Specified by:
getY1in classQuadCurve2D
getP1
public Point2D getP1()
- Returns the curve’s start point.
- Specified by:
getP1in classQuadCurve2D
getCtrlX
public double getCtrlX()
- Returns the x coordinate of the curve’s control
point.
- Specified by:
getCtrlXin classQuadCurve2D
getCtrlY
public double getCtrlY()
- Returns the y coordinate of the curve’s control
point.
- Specified by:
getCtrlYin classQuadCurve2D
getCtrlPt
public Point2D getCtrlPt()
- Returns the curve’s control point.
- Specified by:
getCtrlPtin classQuadCurve2D
getX2
public double getX2()
- Returns the x coordinate of the curve’s end
point.
- Specified by:
getX2in classQuadCurve2D
getY2
public double getY2()
- Returns the y coordinate of the curve’s end
point.
- Specified by:
getY2in classQuadCurve2D
getP2
public Point2D getP2()
- Returns the curve’s end point.
- Specified by:
getP2in classQuadCurve2D
setCurve
public void setCurve(double x1,
double y1,
double cx,
double cy,
double x2,
double y2)
- Changes the geometry of the curve, specifying coordinate values
as double-precision floating-point numbers.
- Specified by:
setCurvein classQuadCurve2D
setCurve
public void setCurve(float x1,
float y1,
float cx,
float cy,
float x2,
float y2)
- Changes the geometry of the curve, specifying coordinate values
as single-precision floating-point numbers.
getBounds2D
public Rectangle2D getBounds2D()
- Determines the smallest rectangle that encloses the
curve’s start, end and control point. As the
illustration below shows, the invisible control point may cause
the bounds to be much larger than the area that is actually
covered by the curve.
|
|||||||||
| Home >> All >> java >> awt >> [ geom overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC