TrimPenData
- 0
Removes selected data from an
HPENDATA object.
HPENDATA TrimPenData( HPENDATA hpndt, DWORD dwTrimOptions, DWORD dwReserved )
Parameters
hpndt
Handle to the
HPENDATA object.
dwTrimOptions
The following option flags are listed in the order in which the trimming
operations are performed. For example, OEM data is removed (TPD_OEMDATA) before
duplicate points (TPD_COLLINEAR).
Constant
| Description
|
TPD_RECALCSIZE
| Recalculate size of pen data and reallocate if smaller.
|
TPD_UPPOINTS
| Remove pen-up strokes from the HPENDATA object.
|
PHW_PRESSURE
| Remove OEM pressure information.
|
PHW_HEIGHT
| Remove OEM height information.
|
PHW_ANGLEXY
| Remove OEM XY-angle information.
|
PHW_ANGLEZ
| Remove OEM Z-angle information.
|
PHW_BARRELROTATION
| Remove OEM barrel rotation information.
|
PHW_OEMSPECIFIC
| Remove OEM-specific value information.
|
PHW_PDK
| Remove per-point Pen Driver Kit (PDK_) information.
|
TPD_PHW
| Remove all OEM and PDK information, but not stroke tick or user data.
|
TPD_OEMDATA
| Remove all OEM values and PDK data.
|
TPD_PENINFO
| Remove PENINFO structure from header. Note that any OEM information present is discarded.
|
TPD_COLLINEAR
| Remove collinear and duplicate (coincident) points. There may not be any OEM
data.
|
TPD_USER
| Remove per-stroke user information.
|
TPD_TIME
| Remove per-stroke timing information.
|
TPD_EMPTYSTROKES
| Remove all strokes with 0 points.
|
TPD_EVERYTHING
| Remove everything possible except pen-down strokes. This includes both TPD_
and PHW_ flags.
|
dwReserved
Must be 0.
Return Value
Returns PDR_OK if successful; otherwise, it returns one of the following
negative values:
Constant
| Description
|
PDR_COMPRESSED
| The pen data was compressed.
|
PDR_ERROR
| An unspecified memory error occurred.
|
PDR_MEMERR
| Memory error.
|
PDR_OEMDATAERR
| The pen data does not have specific pressure or height (PHW_) information.
Thus, the specified PHW_ data could not be selectively trimmed. Use TPD_OEMDATA to
remove all OEM information.
|
PDR_PNDTERR
| Invalid pen data.
|
PDR_VERSIONERR
| A version 1.0 pen data object could not be converted to the 2.0 format.
|
Comments
TrimPenData supplements the capabilities of
CompressPenData. Together, these two functions replace the version 1.0 Pen API function
CompactPenData, which is supported for compatibility only.
The data that
hpndt points to must not be compressed. If it is,
TrimPenData simply retrieves the original (untrimmed) pen data.
See Also
CompactPenData,
CompressPenData, PDK_
- Software for developers
-
Delphi Components
.Net Components
Software for Android Developers
- More information resources
-
MegaDetailed.Net
Unix Manual Pages
Delphi Examples
- Databases for Amazon shops developers
-
Amazon Categories Database
Browse Nodes Database