Go to: Contents |
Native Library API Reference |
Functions
FineRecognizeBlocks Function
This function recognizes a set of blocks on the image. Image analysis is not
performed, and the user is responsible for passing a correctly defined set of
blocks to this method. For example, you can select the blocks that must be
recognized from the layout returned by the
FineAnalyzeImage function. Otherwise, define the blocks you need
to recognize manually: specify the region and fill in the Attributes
field for each.
C Syntax
TFineErrorCode FineRecognizeBlocks(
const TLanguageID languages[],
const TFinePatternsPtr patterns,
const TFinePatternsPtr* cjkPatterns,
const TFineDictionaryPtr dictionaries[],
const CFineImage* image,
int blockCount,
const CFineTextBlock* blocks,
TFineImageProcessingOptions imageProcessingOptions,
TFineRecognitionMode recMode,
TFineRecognitionConfidenceLevel confidenceLevel,
CFineLayout** layoutBuff,
TFineProgressCallbackFunction progressCallback,
TFinePrebuiltDataCallbackFunction prebuiltDataCallback
);
Parameters
- languages[]
- [in] The list of language IDs as an array of the
TLanguageID constants terminated by LID_Undefined.
We do not recommend adding more than two recognition
languages to the list.
- patterns
- [in] The address of
patterns as a
TFinePatternsPtr variable.
- cjkPatterns
- [in] The zero-terminated list of pointers to
the patterns for
CJK languages.
- dictionaries[]
- [in] The zero-terminated list of
dictionaries as an
array of the
TFineDictionaryPtr variables.
- image
- [in] The image to be recognized as a
CFineImage variable.
- blockCount
- [in] The number of blocks passed for recognition.
- blocks
- [in] The array of blocks that must be recognized. For each block, only the
Attributes, RegionRectsCount, and RegionRects fields
must be filled in.
- imageProcessingOptions
- [in] OR combination of the
TFineImageProcessingOptionsFlags
constants
which define the image processing parameters.
- recMode
- [in] The TFineRecognitionMode
constant which sets the recognition mode.
- confidenceLevel
- [in] The
TFineRecognitionConfidenceLevel
constant which sets the
recognition confidence level.
- layoutBuff
- [out] A pointer to pointer variable that receives the interface pointer of
a CFineLayout variable which describes the
recognized text. This pointer must be released afterwards with the help of the
FineFreeMemory function.
- progressCallback
- [in] The TFineProgressCallbackFunction
callback function that delivers the progress information.
It can be 0.
- prebuiltDataCallback
- [in] The
TFinePrebuiltDataCallbackFunction callback function that delivers the
information about the document layout, text blocks and lines before the
text recognition.
It can be 0.
Return value
The function returns the standard return values of ABBYY Mobile OCR Engine functions.
See also
Working with Languages
Working with Dictionaries