PDFPAGE_CurveTo
IPDFDocument3 :: PDF page methods

See Also Example
Collapse All

This method creates a Bézier cubic curve segment.

Syntax

HRESULT PDFPAGE_CurveTo (
DOUBLE firstX,
DOUBLE firstY,
DOUBLE secondX,
DOUBLE secondY,
DOUBLE thirdX,
DOUBLE thirdY
)
Parameters
firstX
X coordinate of 1st control point

firstY
Y coordinate of 1st control point

secondX
X coordinate of 2nd control point

secondY
Y coordinate of 2nd control point

thirdX
X coordinate of end point

thirdY
Y coordinate of end point

Return value
If successful, this method returns S_OK. If it fails, this method should return one of the error values.

Remarks

This method appends a cubic Bézier curve to the current path. The curve extends from the current point to the point (thirdX, thirdY), using (firstX, firtsY) and (secondX, secondY) as the Bézier control points. The new current point is (thirdX, thirdY).

Equivalent in new interface: IPDFDocument4::DrawCurveTo.

Example

CurveTo Example

Delphi
[copy to clipboard]
{ PDF object is supposed to be created }
PDF.BeginDoc;
PDF.PDFPAGE_MoveTo(50, 200);
PDF.PDFPAGE_CurveTo(80, 70, 200, 200, 300, 90);
PDF.PDFPAGE_Stroke;
PDF.EndDoc;
C/C++
[copy to clipboard]
// PDF object is supposed to be created
PDF->BeginDoc();
PDF->PDFPAGE_MoveTo(50, 200);
PDF->PDFPAGE_CurveTo(80, 70, 200, 200, 300, 90);
PDF->PDFPAGE_Stroke();
PDF->EndDoc();
C#
[copy to clipboard]
// PDF object is supposed to be created
PDF.BeginDoc();
PDF.PDFPAGE_MoveTo(50, 200);
PDF.PDFPAGE_CurveTo(80, 70, 200, 200, 300, 90);
PDF.PDFPAGE_Stroke();
PDF.EndDoc();
Visual Basic
[copy to clipboard]
' PDF object is supposed to be created
PDF.BeginDoc
PDF.PDFPAGE_MoveTo 50, 200
PDF.PDFPAGE_CurveTo 80, 70, 200, 200, 300, 90
PDF.PDFPAGE_Stroke
PDF.EndDoc

See Also

Reference