com.itextpdf.awt.geom
Class CubicCurve2D

java.lang.Object
  extended by com.itextpdf.awt.geom.CubicCurve2D
All Implemented Interfaces:
Shape, Cloneable
Direct Known Subclasses:
CubicCurve2D.Double, CubicCurve2D.Float

public abstract class CubicCurve2D
extends Object
implements Shape, Cloneable


Nested Class Summary
static class CubicCurve2D.Double
           
static class CubicCurve2D.Float
           
 
Constructor Summary
protected CubicCurve2D()
           
 
Method Summary
 Object clone()
           
 boolean contains(double px, double py)
           
 boolean contains(double rx, double ry, double rw, double rh)
           
 boolean contains(Point2D p)
           
 boolean contains(Rectangle2D r)
           
 Rectangle getBounds()
           
abstract  Point2D getCtrlP1()
           
abstract  Point2D getCtrlP2()
           
abstract  double getCtrlX1()
           
abstract  double getCtrlX2()
           
abstract  double getCtrlY1()
           
abstract  double getCtrlY2()
           
 double getFlatness()
           
static double getFlatness(double[] coords, int offset)
           
static double getFlatness(double x1, double y1, double ctrlx1, double ctrly1, double ctrlx2, double ctrly2, double x2, double y2)
           
 double getFlatnessSq()
           
static double getFlatnessSq(double[] coords, int offset)
           
static double getFlatnessSq(double x1, double y1, double ctrlx1, double ctrly1, double ctrlx2, double ctrly2, double x2, double y2)
           
abstract  Point2D getP1()
           
abstract  Point2D getP2()
           
 PathIterator getPathIterator(AffineTransform t)
           
 PathIterator getPathIterator(AffineTransform at, double flatness)
           
abstract  double getX1()
           
abstract  double getX2()
           
abstract  double getY1()
           
abstract  double getY2()
           
 boolean intersects(double rx, double ry, double rw, double rh)
           
 boolean intersects(Rectangle2D r)
           
 void setCurve(CubicCurve2D curve)
           
 void setCurve(double[] coords, int offset)
           
abstract  void setCurve(double x1, double y1, double ctrlx1, double ctrly1, double ctrlx2, double ctrly2, double x2, double y2)
           
 void setCurve(Point2D[] points, int offset)
           
 void setCurve(Point2D p1, Point2D cp1, Point2D cp2, Point2D p2)
           
static int solveCubic(double[] eqn)
           
static int solveCubic(double[] eqn, double[] res)
           
 void subdivide(CubicCurve2D left, CubicCurve2D right)
           
static void subdivide(CubicCurve2D src, CubicCurve2D left, CubicCurve2D right)
           
static void subdivide(double[] src, int srcOff, double[] left, int leftOff, double[] right, int rightOff)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.itextpdf.awt.geom.Shape
getBounds2D
 

Constructor Detail

CubicCurve2D

protected CubicCurve2D()
Method Detail

getX1

public abstract double getX1()

getY1

public abstract double getY1()

getP1

public abstract Point2D getP1()

getCtrlX1

public abstract double getCtrlX1()

getCtrlY1

public abstract double getCtrlY1()

getCtrlP1

public abstract Point2D getCtrlP1()

getCtrlX2

public abstract double getCtrlX2()

getCtrlY2

public abstract double getCtrlY2()

getCtrlP2

public abstract Point2D getCtrlP2()

getX2

public abstract double getX2()

getY2

public abstract double getY2()

getP2

public abstract Point2D getP2()

setCurve

public abstract void setCurve(double x1,
                              double y1,
                              double ctrlx1,
                              double ctrly1,
                              double ctrlx2,
                              double ctrly2,
                              double x2,
                              double y2)

setCurve

public void setCurve(Point2D p1,
                     Point2D cp1,
                     Point2D cp2,
                     Point2D p2)

setCurve

public void setCurve(double[] coords,
                     int offset)

setCurve

public void setCurve(Point2D[] points,
                     int offset)

setCurve

public void setCurve(CubicCurve2D curve)

getFlatnessSq

public double getFlatnessSq()

getFlatnessSq

public static double getFlatnessSq(double x1,
                                   double y1,
                                   double ctrlx1,
                                   double ctrly1,
                                   double ctrlx2,
                                   double ctrly2,
                                   double x2,
                                   double y2)

getFlatnessSq

public static double getFlatnessSq(double[] coords,
                                   int offset)

getFlatness

public double getFlatness()

getFlatness

public static double getFlatness(double x1,
                                 double y1,
                                 double ctrlx1,
                                 double ctrly1,
                                 double ctrlx2,
                                 double ctrly2,
                                 double x2,
                                 double y2)

getFlatness

public static double getFlatness(double[] coords,
                                 int offset)

subdivide

public void subdivide(CubicCurve2D left,
                      CubicCurve2D right)

subdivide

public static void subdivide(CubicCurve2D src,
                             CubicCurve2D left,
                             CubicCurve2D right)

subdivide

public static void subdivide(double[] src,
                             int srcOff,
                             double[] left,
                             int leftOff,
                             double[] right,
                             int rightOff)

solveCubic

public static int solveCubic(double[] eqn)

solveCubic

public static int solveCubic(double[] eqn,
                             double[] res)

contains

public boolean contains(double px,
                        double py)
Specified by:
contains in interface Shape

contains

public boolean contains(double rx,
                        double ry,
                        double rw,
                        double rh)
Specified by:
contains in interface Shape

intersects

public boolean intersects(double rx,
                          double ry,
                          double rw,
                          double rh)
Specified by:
intersects in interface Shape

contains

public boolean contains(Point2D p)
Specified by:
contains in interface Shape

intersects

public boolean intersects(Rectangle2D r)
Specified by:
intersects in interface Shape

contains

public boolean contains(Rectangle2D r)
Specified by:
contains in interface Shape

getBounds

public Rectangle getBounds()
Specified by:
getBounds in interface Shape

getPathIterator

public PathIterator getPathIterator(AffineTransform t)
Specified by:
getPathIterator in interface Shape

getPathIterator

public PathIterator getPathIterator(AffineTransform at,
                                    double flatness)
Specified by:
getPathIterator in interface Shape

clone

public Object clone()
Overrides:
clone in class Object


Copyright © 2013. All Rights Reserved.