IStrokeBuilder::CreateStroke method (rtscom.h)

Creates strokes on an ink object by using packet data that came from a RealTimeStylus Class object.

Syntax

HRESULT CreateStroke(
  [in]      ULONG                 cPktBuffLength,
  [in]      const LONG            *pPackets,
  [in]      ULONG                 cPacketProperties,
  [in]      const PACKET_PROPERTY *pPacketProperties,
  [in]      FLOAT                 fInkToDeviceScaleX,
  [in]      FLOAT                 fInkToDeviceScaleY,
  [in, out] IInkStrokeDisp        **ppIInkStroke
);

Parameters

[in] cPktBuffLength

The number of LONGs in the pPackets array not the size in bytes. Valid values are between 0 and 0x000FFFFF, inclusive.

[in] pPackets

A pointer to the start of the packet data.

[in] cPacketProperties

The count of longs in the pPacketProperties buffer. This is the number of packets multiplied by the number of properties. Valid values are between 0 and 32, inclusive.

[in] pPacketProperties

The buffer containing the packet properties.

[in] fInkToDeviceScaleX

The horizontal, or x-axis, conversion factor for the horizontal axis from ink space to digitizer coordinates.

[in] fInkToDeviceScaleY

The vertical, or y-axis, conversion factor for the vertical axis from ink space to digitizer coordinates.

[in, out] ppIInkStroke

A pointer to the newly created stroke. This value can be NULL.

Return value

For a description of the return values, see RealTimeStylus Classes and Interfaces.

Remarks

The fInkToDeviceScaleX and fInkToDeviceScaleY parameters affect the internal representation of strokes created with the IStrokeBuilder::CreateStroke Method method. Multiply the x-coordinate in ink space by fInkToDeviceScaleX to get the x-coordinate in digitizer units. Multiply the y-coordinate in ink space by fInkToDeviceScaleY to get the y-coordinate in digitizer units.

To retrieve the scale parameters, use IRealTimeStylus::GetPacketDescriptionData Method.

Requirements

Requirement Value
Minimum supported client Windows XP Tablet PC Edition [desktop apps only]
Minimum supported server None supported
Target Platform Windows
Header rtscom.h
DLL RTSCom.dll

See also

DynamicRenderer Class

IStrokeBuilder

IStrokeBuilder::BeginStroke Method

IStrokeBuilder::EndStroke Method

RealTimeStylus Class

StrokeBuilder Class