@Override // from interface IShape public Rectangle bounds (Rectangle target) { float x1 = x1(), y1 = y1(), x2 = x2(), y2 = y2(); float ctrlx1 = ctrlX1(), ctrly1 = ctrlY1(); float ctrlx2 = ctrlX2(), ctrly2 = ctrlY2(); float rx1 = Math.min(Math.min(x1, x2), Math.min(ctrlx1, ctrlx2)); float ry1 = Math.min(Math.min(y1, y2), Math.min(ctrly1, ctrly2)); float rx2 = Math.max(Math.max(x1, x2), Math.max(ctrlx1, ctrlx2)); float ry2 = Math.max(Math.max(y1, y2), Math.max(ctrly1, ctrly2)); target.setBounds(rx1, ry1, rx2 - rx1, ry2 - ry1); return target; }
@Override // from interface ICubicCurve public Point ctrlP2 () { return new Point(ctrlX2(), ctrlY2()); }
@Override // from interface IShape public Rectangle bounds (Rectangle target) { float x1 = x1(), y1 = y1(), x2 = x2(), y2 = y2(); float ctrlx1 = ctrlX1(), ctrly1 = ctrlY1(); float ctrlx2 = ctrlX2(), ctrly2 = ctrlY2(); float rx1 = Math.min(Math.min(x1, x2), Math.min(ctrlx1, ctrlx2)); float ry1 = Math.min(Math.min(y1, y2), Math.min(ctrly1, ctrly2)); float rx2 = Math.max(Math.max(x1, x2), Math.max(ctrlx1, ctrlx2)); float ry2 = Math.max(Math.max(y1, y2), Math.max(ctrly1, ctrly2)); target.setBounds(rx1, ry1, rx2 - rx1, ry2 - ry1); return target; }
@Override // from interface ICubicCurve public Point ctrlP2 () { return new Point(ctrlX2(), ctrlY2()); }
@Override // from interface ICubicCurve public CubicCurve clone () { return new CubicCurve(x1(), y1(), ctrlX1(), ctrlY1(), ctrlX2(), ctrlY2(), x2(), y2()); }
@Override // from interface ICubicCurve public float flatnessSq () { return CubicCurves.flatnessSq(x1(), y1(), ctrlX1(), ctrlY1(), ctrlX2(), ctrlY2(), x2(), y2()); }
@Override // from interface ICubicCurve public float flatness () { return CubicCurves.flatness(x1(), y1(), ctrlX1(), ctrlY1(), ctrlX2(), ctrlY2(), x2(), y2()); }
@Override // from interface ICubicCurve public float flatnessSq () { return CubicCurves.flatnessSq(x1(), y1(), ctrlX1(), ctrlY1(), ctrlX2(), ctrlY2(), x2(), y2()); }
@Override // from interface ICubicCurve public float flatness () { return CubicCurves.flatness(x1(), y1(), ctrlX1(), ctrlY1(), ctrlX2(), ctrlY2(), x2(), y2()); }
@Override // from interface ICubicCurve public CubicCurve clone () { return new CubicCurve(x1(), y1(), ctrlX1(), ctrlY1(), ctrlX2(), ctrlY2(), x2(), y2()); }