cubicTo

fun cubicTo(x1: Float, y1: Float, x2: Float, y2: Float, x3: Float, y3: Float): Path

Adds cubic from last point towards (x1, y1), then towards (x2, y2), ending at (x3, y3). If Path is empty, or last PathVerb is PathVerb.CLOSE, last point is set to (0, 0) before adding cubic.

Appends PathVerb.MOVE to verb array and (0, 0) to Point array, if needed; then appends PathVerb.CUBIC to verb array; and (x1, y1), (x2, y2), (x3, y3) to Point array.

Return

reference to Path

Parameters

x1

first control Point of cubic on x-axis

y1

first control Point of cubic on y-axis

x2

second control Point of cubic on x-axis

y2

second control Point of cubic on y-axis

x3

end Point of cubic on x-axis

y3

end Point of cubic on y-axis


fun cubicTo(p1: Point, p2: Point, p3: Point): Path

Adds cubic from last point towards Point p1, then towards Point p2, ending at Point p3. If Path is empty, or last PathVerb is PathVerb.CLOSE, last point is set to (0, 0) before adding cubic.

Appends PathVerb.MOVE to verb array and (0, 0) to Point array, if needed; then appends PathVerb.CUBIC to verb array; and Point p1, p2, p3 to Point array.

Return

reference to Path

Parameters

p1

first control Point of cubic

p2

second control Point of cubic

p3

end Point of cubic