Skip to main content
Version: API v2 Preview

Bezier

Kind: class
Module/package: com.pdfdancer.common.model.path
SDK: com.pdfdancer.client:pdfdancer-client-java 2.0.0

Represents a cubic Bezier curve path segment defined by four control points. This class implements a cubic Bezier curve with start point, two control points, and end point, providing smooth curved path segments for complex vector graphics. Includes mathematical evaluation methods for point calculation along the curve.

Declaration

public class com.pdfdancer.common.model.path.Bezier extends com.pdfdancer.common.model.path.PathSegment

Members

constructor

public com.pdfdancer.common.model.path.Bezier()

Default constructor for deserialization.

constructor

public com.pdfdancer.common.model.path.Bezier(com.pdfdancer.common.model.Point, com.pdfdancer.common.model.Point, com.pdfdancer.common.model.Point, com.pdfdancer.common.model.Point)

Creates a cubic Bezier curve with the specified control points.

evaluate

public com.pdfdancer.common.model.Point evaluate(double)

Evaluates a point on the Bezier curve for the given parameter value. This method uses the cubic Bezier mathematical formula to calculate the exact coordinates at any point along the curve.

getP0

public com.pdfdancer.common.model.Point getP0()

Returns the starting point p0 of this Bezier segment.

getP1

public com.pdfdancer.common.model.Point getP1()

Returns the first control point p1 of this Bezier segment.

getP2

public com.pdfdancer.common.model.Point getP2()

Returns the second control point p2 of this Bezier segment.

getP3

public com.pdfdancer.common.model.Point getP3()

Returns the ending point p3 of this Bezier segment.

setP0

public void setP0(com.pdfdancer.common.model.Point)

setP1

public void setP1(com.pdfdancer.common.model.Point)

setP2

public void setP2(com.pdfdancer.common.model.Point)

setP3

public void setP3(com.pdfdancer.common.model.Point)

View source at 9c04036fe114