| MIL 10 Reference
| Customize Help
| Save Settings

MstrExpert



See also
Availability
Not available in MIL-Lite
Available in MIL

Available on Windows
Available on Linux

Available on Non-Matrox computer
Available on Matrox 4Sight-X
Available on Matrox 4Sight GP
Available on Matrox Supersight
function map Function map
Examples
None.
Synopsis
Makes a diagnosis of the String Reader context and reports configuration problems.
Syntax
void MstrExpert(
MIL_ID ContextId, //in
const MIL_ID *ImageArrayPtr, //in
const void *TargetStringArrayPtr, //in
MIL_INT NbImages, //in
MIL_ID ResultId, //in
MIL_INT64 ControlFlag //in
)
Description

This function analyzes the consistency of a String Reader context using a specified image and a target string. Retrieve results using MstrGetResult(); this function returns error and/or warning codes for problems found. Use MstrInquire() to retrieve the meaning associated with these codes.

When the diagnosis of the String Reader context does not cause a general error (see MstrGetResult() with M_GENERAL), the context is ready to be used to read the image provided to MstrExpert(). You can call MstrExpert() multiple times to find and correct problems in the context.

You can limit the verify operation to a region of the image buffer, using a rectangular ROI set with MbufSetRegion().

Note that this function is only available for a font-based context.

Note that this function reference has not been updated for a MIL system added during a MIL update. Refer to the MIL system's release note to see if there is complementary information.
Parameters
This function is not supported on the selected boards.
Parameters
ContextId

Specifies the identifier of the String Reader context. The String Reader context must have been previously allocated on the required system using MstrAlloc().

ImageArrayPtr

Specifies the identifier of the image to analyze. Note that you cannot provide more than one image.

This image buffer can only have a rectangular region of interest (ROI) defined using MbufSetRegion() (with or without rotation). In addition, the region must be defined in vector format from a graphics list (M_VECTOR or M_VECTOR_AND_RASTER). An error will be generated if the ROI is only in raster format (M_RASTER) or a non-rectangular shape.

TargetStringArrayPtr

Specifies the identifier of the string to locate. This string represents the expected strings to locate in each image analyzed using MstrRead(). The string array must be of the right type for the encoding scheme selected (MstrControl() with M_ENCODING). Only one string is supported.

NbImages

Specifies the number of images to analyze. This parameter must be set to 1.

ResultId

Specifies the identifier of the String Reader result buffer in which to save the results of MstrExpert().

ControlFlag

Specifies the type of analysis to perform with MstrExpert().

To specify the type of analysis to perform, set this parameter to one of the following values. Except for M_DEFAULT, the following values can be added together.

function map For specifying the type of analysis to perform
CollapseValue Description
Collapse M_DEFAULT

Specifies to report errors and warnings.

Collapse M_ERRORS

Specifies to report errors.

Collapse M_WARNINGS

Specifies to report warnings.

Compilation information
Header Include mil.h.
Library Use mil.lib; milstr.lib.
DLL Requires mil.dll; milstr.dll.
FONT BASED PROC RASTER DEFAULT ERRORS WARNINGS