Home| base |src.lib|graphic|fbuffer| FrameBufferMakeClip Index

FrameBufferMakeClip

Syntax
struct FrameBufferClip *FrameBufferMakeClip(int wdt,int hgt,int num, int *px, int *py,int *t);
Header
base/rfbuffer.h
Library
rfbuf
Description

The FrameBufferMakeClip function creates a clipping polygon.

The arguments x and y are applied as an offset to each vertex in the clipping polygon. The polygon is expected to lie with the rectangle whose size is given by the arguments wdt and hgt.

The number of vertices of the clipping polygon is given by the argument num. The arrays containing the X and Y coordinates of each vertex are pointed to by the arguments px and y.

A polygon can be constructed from straight line segments or bezier curves. The array pointed to by the argument t determines what kind of line segment is used to join to a vertex. If the corresponding entry in the array equals zero, then the segment between the current point and the next point is a straight line; if the entry is (1) then the connecting segment is a bezier curve and the next two vertices are the control points, the curve connects to the third point.

Returns
Returns a pointer to the structure containing the clipping polygon on success. On error, a NULL pointer is returned.
Errors
On error, a NULL pointer is returned.
Example
None