GPE::Line

This method is called before and after a sequence of line segments, which are drawn as a path.

Syntax

SCODE GPE::Line( GPELineParms *pLineParms, EGPEPhase phase );

Parameters

pLineParms
[IN] Pointer to a GPELineParms structure contining parameters for the line.
phase
Phase of drawing for this call, either gpePrepare or gpeComplete.

Remarks

When called before a line sequence, the phase parameter has the value gpePrepare. Once the sequence is complete, the GDI calls this method with the value gpeComplete in the phase parameter.

The GPE::Line method examines the line parameters to determine whether the operation can be accelerated. It also places a pointer to a function to be called once per line segment into the pLine member of the GPELineParms structure. To use the emulated line drawing code supplied as part of the GPE, the following code should be executed.

pLineParms->pLine = EmulatedLine;
return S_OK;

If the pBltParms prclClip member is not NULL, the sequence of lines is clipped to a single clipped rectangle. If hardware acceleration of the line drawing is enabled and the hardware provides clipping registers, the driver prepares the clipping registers, and then places NULL in the pBltParms prclClip member. This ensures that the GPE does not attempt to clip the individual line segments.