L_DocSetOMROptions
#include "ltdoc.h"
L_LTDOC_API L_INT L_DocSetOMROptions(hDoc, pOMROpts)
L_HDOC hDoc; |
/* handle to the OCR document */ |
pOMROPTIONS pOMROpts; |
/* pointer to OMROPTIONS */ |
Sets the OMR options to be used in next recognition process.
Parameter |
Description |
hDoc |
Handle to the OCR document. |
pOMROpts |
Pointer to an OMROPTIONS structure which contains the options to be set. |
Returns
SUCCESS |
The function was successful. |
< 1 |
An error occurred. Refer to Return Codes. |
Comments
Sets the OMR options to be used in the next recognition process.
This function will be used only when the recognition module is RECOGMODULE_OMR.
To get the current hand print options, call L_DocGetOMROptions.
To recognize a page, call L_DocRecognize.
Required DLLs and Libraries
LTDOC For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
See Also
Functions: |
L_DocSetRecognizeModuleTradeOff, L_DocGetRecognizeModuleTradeOff, L_DocSetMOROptions, L_DocGetMOROptions, L_DocSetHandPrintOptions, L_DocGetHandPrintOptions, L_DocGetOMROptions |
Topics: |
|
|
Example
L_INT DocSetOMROptionsExample(L_HDOC hDoc) { L_INT nRet; OMROPTIONS OMROpts; ZeroMemory(&OMROpts, sizeof(OMROPTIONS)); nRet = L_DocGetOMROptions(hDoc, &OMROpts, sizeof(OMROPTIONS)); if(nRet != SUCCESS) return nRet; #if !defined(LEADTOOLS_V16_OR_LATER) if (!OMROpts.bFill) OMROpts.bFill = TRUE; if (OMROpts.Frame != OMR_FRAME_YES) OMROpts.Frame = OMR_FRAME_YES; if (OMROpts.Sense != OMR_SENSE_NORMAL) OMROpts.Sense = OMR_SENSE_NORMAL; #else if (OMROpts.Frame != OMR_WITH_FRAME) OMROpts.Frame = OMR_WITH_FRAME; if (OMROpts.Sense != OMR_SENSE_HIGHEST) OMROpts.Sense = OMR_SENSE_HIGHEST; #endif // #if !defined(LEADTOOLS_V16_OR_LATER) nRet = L_DocSetOMROptions(hDoc, &OMROpts); if(nRet != SUCCESS) return nRet; return SUCCESS; }