GetCurvePoints method (Main Control)

C++ Builder example

Delphi example

 

Builder Syntax

int GetCurvePoints(PPoint apUserPoint, unsigned uUserPointCount, L_PINT pnCurve, L_PUINT puPointCount, unsigned uFlags);

Delphi Syntax

Function GetCurvePoints (apUserPoint: pPOINT; uUserPointCount: L_UINT; pnCurve: L_PINT; puPointCount: L_PUINT; uFlags: L_UINT): L_INT;

Overview

Refer to Applying Artistic Effects.

Remarks

Updates the pnCurve array based on a curve or lines that pass through the specified points.

This method will update pnCurve using either the best curve or lines that pass through the points specified in the apUserPoint parameter. The points in the array may be sorted or not. In most cases, this method is used with the FreeHandShear, or FreeHandWave methods.

To compute the size of the pnCurve array:

Size = Maximum (apUserPoint.x) + 1;

The values stored in pnCurve represent the y coordinates of the calculated curve based on the points in the apUserPoint array. In the pnCurve array there can be only one y value for each x coordinate. Therefore, circles, ellipses, and spirals cannot be represented by pnCurve.

The x coordinates for the user points are sorted internally automatically.

See Also

Elements:

FreeHandShear method, FreeHandWave method

Topics:

Raster Images: Doing Geometric Transformations