IInkAnalyzer::LoadResults method

Loads saved analysis results into the IInkAnalyzer.

Syntax

HRESULT LoadResults(
  [in]          ULONG        ulDataSize,
  [in]          BYTE         *pbSerializedResults,
  [in]          ULONG        ulStrokeIdsCount,
  [in]          LONG         *plOriginalStrokeIds,
  [in]          LONG         *plNewStrokeIds,
  [out, retval] VARIANT_BOOL *pfSuccessful
);

Parameters

ulDataSize [in]

The number of bytes in pbSerializedResults.

pbSerializedResults [in]

The serialized analysis results.

ulStrokeIdsCount [in]

The number of stroke identifiers.

plOriginalStrokeIds [in]

The array of original stroke identifiers.

plNewStrokeIds [in]

The array of new stroke identifiers.

pfSuccessful [out, retval]

VARIANT_TRUE if loading was successful; otherwise, VARIANT_FALSE.

Return value

For a description of the return values, see Classes and Interfaces - Ink Analysis.

Remarks

When the IInkAnalyzer adds a IContextNode from the saved results, it assigns a new globally unique identifier (GUID) to the IContextNode (see IContextNode::GetPropertyData and Context Node Properties).

This method adds the saved analysis results to the existing IContextNode tree. To ensure that the combined results are ordered correctly, add the area containing the loaded context nodes to the IInkAnalyzer object's dirty region (see IInkAnalyzer::GetDirtyRegion Method) and reanalyze the ink.

The IInkAnalyzer::SaveResults Method, IInkAnalyzer::SaveResultsForNodes Method, and IInkAnalyzer::SaveResultsForStrokes Method methods do not save the packet data along with the analysis results.

Each identifier in plOriginalStrokeIds is the stroke identifier for the stroke in the saved analysis results. Each identifier in plNewStrokeIds is the new identifier with which to replace the original identifier in the loaded analysis results.

If a saved analysis hint conflicts with an existing analysis hint, the IInkAnalyzer does not load the saved hint but does load the rest of the saved results. However, if the IInkAnalyzer loads results for a stroke that is within the area of a saved analysis hint that the IInkAnalyzer does not load, the IInkAnalyzer adds the bounding box of the stroke to the IInkAnalyzer object's dirty region. Also, if the IInkAnalyzer loads results for a stroke that is within an existing analysis hint's area, the IInkAnalyzer also adds the bounding box of the stroke to the IInkAnalyzer object's dirty region. For more information about analysis hints, see Analysis Hint Properties.

This method may raise the _IAnalysisProxyEvents::ContextNodeCreated, _IAnalysisProxyEvents::ContextNodeLinkAdding, and _IAnalysisProxyEvents::ContextNodePropertiesUpdated events as it loads the saved results.

Requirements

Requirement Value
Minimum supported client
Windows XP Tablet PC Edition [desktop apps only]
Minimum supported server
None supported
Header
IACom.h (also requires IACom_i.c)
DLL
IACom.dll

See also

IInkAnalyzer

IContextNode

IInkAnalyzer::GetDirtyRegion Method

IInkAnalyzer::SetDirtyRegion Method

IInkAnalyzer::SaveResults Method

IInkAnalyzer::SaveResultsForNodes Method

IInkAnalyzer::SaveResultsForStrokes Method

Ink Analysis Reference