Click here to show toolbars of the Web Online Help System: show toolbars |
MIL_ID ContextOrResultDmrId, | //in |
MIL_INT64 ControlType, | //in |
MIL_DOUBLE ControlValue | //in |
This function allows you to control a setting of a SureDotOCR context or a SureDotOCR result buffer. This function also allows you to add or delete a font or string model from a context, or to remove all results from a result buffer. To inquire about a context, call MdmrInquire(). To get results from a result buffer, call MdmrGetResult().
To control the fonts and string models held by a SureDotOCR context, call MdmrControlFont() and MdmrControlStringModel(), respectively.
For a successful read operation, you must specify an explicit value for the control types that set the diameter of the dots in the string's characters (M_DOT_DIAMETER) and the dimensions of the rectangular region in which to read strings (M_STRING_BOX_HEIGHT and M_STRING_BOX_WIDTH).
You must preprocess the SureDotOCR context after you have finished adjusting context settings and before calling MdmrRead(). To know if a context needs to be preprocessed, call MdmrInquire() with M_PREPROCESSED.
Specifies the identifier of the SureDotOCR context or result buffer to control. The context must have been previously allocated on the system using MdmrAlloc(). The result buffer must have been previously allocated on the system using MdmrAllocResult().
Specifies the setting to change.
See the Parameter associations section for possible values that can be specified.
Specifies the setting's new value.
See the Parameter associations section for possible values that can be specified.
The tables below list possible values for the ControlType and ControlValue parameters.
The following ControlType and corresponding ControlValue parameter settings are used to control a setting of the SureDotOCR context specified with the ContextOrResultDmrId parameter. SureDotOCR can only read strings that adhere to these settings (they apply to all strings in the context).
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
ControlValue | |||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the diameter of the dots that make up the characters in the strings. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the diameter, in pixels. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the foreground of the characters in the strings. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_FOREGROUND_BLACK. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that the string can be read if the foreground of its characters is darker than the background. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that the string can be read if the foreground of its characters is lighter than the background. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the maximum pixel intensity of a character's dots. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default value; the default value is 255.0. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the maximum pixel intensity. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets how to establish the maximum pixel intensity of a character's dots. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_AUTO. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to automatically establish the maximum pixel intensity of a character's dots. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to use the maximum pixel intensity value set with M_MAX_INTENSITY. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the minimum contrast of a character. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default value; the default value is 15.0. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the minimum contrast. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets how to establish the minimum contrast (difference in pixel intensity) between a character (foreground) and its background. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_AUTO. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to automatically establish the minimum contrast of characters. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to use the minimum contrast value set with M_MIN_CONTRAST. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the minimum pixel intensity of a character's dots. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default value; the default value is 0.0. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the minimum pixel intensity. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets how to establish the minimum pixel intensity of a character's dots. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_AUTO. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to automatically establish the minimum pixel intensity of character dots. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to use the minimum pixel intensity value set with M_MIN_INTENSITY. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the value with which to determine the maximum distance between two characters in a string. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default value; the default value is 3.0. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the maximum distance value. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets how to determine the maximum distance between two characters in a string. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_CHAR_WIDTH_FACTOR. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that the maximum distance between two characters in a string is determined by multiplying the M_SPACE_SIZE_MAX value by the string's maximum character width, in pixels. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies no maximum space size. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the value with which to determine the minimum distance between two characters in a string. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default value; the default value is 1.0. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the minimum distance value. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets how to determine the minimum distance between two characters in a string. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_CHAR_WIDTH_FACTOR. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that the minimum distance between two characters in a string is determined by multiplying the M_SPACE_SIZE_MIN value by the string's maximum character width, in pixels. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies no minimum space size. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the height of the rectangular region that encloses the strings to read. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the height, in pixels. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets how to establish the size of the rectangular region that encloses the strings to read. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_USER_DEFINED. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that the size of the rectangular region in which to read strings is defined by the M_STRING_BOX_HEIGHT and M_STRING_BOX_WIDTH settings. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the width of the rectangular region that encloses the strings to read. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the width, in pixels. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the maximum read time for MdmrRead(), in msec. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default value; the default value is 2000.0 msec. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies an infinite amount of read time. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the maximum read time, in msec. |
The following ControlType and corresponding ControlValue parameter settings are used to add fonts or string models to, or delete fonts or string models from, the SureDotOCR context specified with the ContextOrResultDmrId parameter.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
ControlValue | |||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Adds an empty font to the context. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_NEW_LABEL. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to add a font with an automatically assigned label. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to add a font with the indicated label, as an integer. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Deletes one or all fonts from the context. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_ALL. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to delete the font by indicating its index. |
||||||||||||||||||||||||||||||||||||||
Parameters | |||||||||||||||||||||||||||||||||||||||
Set this parameter to the following: |
|||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to delete the font by indicating its label. |
||||||||||||||||||||||||||||||||||||||
Parameters | |||||||||||||||||||||||||||||||||||||||
Set this parameter to the following: |
|||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to delete all fonts. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Adds an empty string model to a context. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_NEW_LABEL. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to add a string model with an automatically assigned label. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to add a string model with the indicated label, as an integer. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Deletes one or all string models from a context. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_ALL. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to delete the string model by indicating its index. |
||||||||||||||||||||||||||||||||||||||
Parameters | |||||||||||||||||||||||||||||||||||||||
Set this parameter to the following: |
|||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to delete the string model by indicating its label. |
||||||||||||||||||||||||||||||||||||||
Parameters | |||||||||||||||||||||||||||||||||||||||
Set this parameter to the following: |
|||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to delete all string models. |
The following ControlType and corresponding ControlValue parameter settings are used to control the SureDotOCR result buffer specified with the ContextOrResultDmrId parameter.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
ControlValue | |||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Removes all results from the SureDotOCR result buffer. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default behavior. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets whether to return results in pixels or world units. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Same as M_ACCORDING_TO_CALIBRATION. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that results are returned in world units if the result was calculated on an image associated with a camera calibration context; otherwise, specifies that results are returned in pixel units. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that results are returned in pixel units, with respect to the pixel coordinate system. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that results are returned in world units, with respect to the relative coordinate system. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Stops the current read operation. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default behavior. |
Parameters
ContextOrResultDmrId See ContextOrResultDmrId of the main function for a description. ControlType See ControlType of the main function for a description. ControlValue See ControlValue of the main function for a description. |
void MdmrControlDouble
(MIL_ID
ContextOrResultDmrId, MIL_INT64 ControlType,
MIL_DOUBLE ControlValue)
Parameters
ContextOrResultDmrId See ContextOrResultDmrId of the main function for a description. ControlType See ControlType of the main function for a description. ControlValue See ControlValue of the main function for a description. |
Header | Include mil.h. |
Library | Use mil.lib; mildmr.lib. |
DLL | Requires mil.dll; mildmr.dll. |