public class Quadradic extends AbstractSegment
Segment.SplitResults
Modifier and Type | Field and Description |
---|---|
java.awt.geom.Point2D.Double |
p1 |
java.awt.geom.Point2D.Double |
p2 |
java.awt.geom.Point2D.Double |
p3 |
Constructor and Description |
---|
Quadradic() |
Quadradic(double x1,
double y1,
double x2,
double y2,
double x3,
double y3) |
Quadradic(java.awt.geom.Point2D.Double p1,
java.awt.geom.Point2D.Double p2,
java.awt.geom.Point2D.Double p3) |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
clone() |
java.awt.geom.Point2D.Double |
eval(double t) |
java.awt.geom.Point2D.Double |
evalDt(double t) |
protected int |
findRoots(double y,
double[] roots) |
java.awt.geom.Rectangle2D |
getBounds2D() |
double |
getLength() |
double |
getLength(double maxErr) |
Segment |
getSegment(double t0,
double t1) |
double |
maxX() |
double |
maxY() |
double |
minX() |
double |
minY() |
Segment |
reverse() |
void |
subdivide(double t,
Quadradic q0,
Quadradic q1)
Subdivides this Quadradic curve into two curves at given t.
|
void |
subdivide(double t,
Segment s0,
Segment s1)
Subdivides this Quadradic curve into two curves at t.
|
void |
subdivide(Quadradic q0,
Quadradic q1)
Subdivides this Quadradic curve into two curves at t = 0.5.
|
void |
subdivide(Segment s0,
Segment s1)
Subdivides this Quadradic curve into two curves at t = 0.5.
|
protected double |
subLength(double leftLegLen,
double rightLegLen,
double maxErr) |
java.lang.String |
toString() |
matchSign, solveCubic, solveLine, solveQuad, split, splitAfter, splitBefore
public java.awt.geom.Point2D.Double p1
public java.awt.geom.Point2D.Double p2
public java.awt.geom.Point2D.Double p3
public Quadradic()
public Quadradic(double x1, double y1, double x2, double y2, double x3, double y3)
public Quadradic(java.awt.geom.Point2D.Double p1, java.awt.geom.Point2D.Double p2, java.awt.geom.Point2D.Double p3)
public java.lang.Object clone()
clone
in class java.lang.Object
public Segment reverse()
public double minX()
public double maxX()
public double minY()
public double maxY()
public java.awt.geom.Rectangle2D getBounds2D()
protected int findRoots(double y, double[] roots)
findRoots
in class AbstractSegment
public java.awt.geom.Point2D.Double evalDt(double t)
public java.awt.geom.Point2D.Double eval(double t)
public Segment getSegment(double t0, double t1)
public void subdivide(Quadradic q0, Quadradic q1)
q0
- if non-null contains portion of curve from 0->.5q1
- if non-null contains portion of curve from .5->1public void subdivide(double t, Quadradic q0, Quadradic q1)
q0
- if non-null contains portion of curve from 0->t.q1
- if non-null contains portion of curve from t->1.public void subdivide(Segment s0, Segment s1)
s0
- if non-null contains portion of curve from 0->.5s1
- if non-null contains portion of curve from .5->1public void subdivide(double t, Segment s0, Segment s1)
s0
- if non-null contains portion of curve from 0->.5s1
- if non-null contains portion of curve from .5->1protected double subLength(double leftLegLen, double rightLegLen, double maxErr)
public double getLength()
public double getLength(double maxErr)
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2022 Apache Software Foundation. All Rights Reserved.