Classes | |
struct | AsposeOCRProgress |
This structure contains a current recognition state. More... | |
Enumerations | |
enum | ASPOSE_OCR_IMAGE_PROCESSING_STATE { ASPOSE_OCR_START , ASPOSE_OCR_LOADED , ASPOSE_OCR_PREPROCESSED , ASPOSE_OCR_REGIONS_DETECTED , ASPOSE_OCR_TEXT_RECOGNIZED } |
Functions | |
DLL_PUBLIC size_t | aspose::ocr::page (const char *image_path, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | aspose::ocr::page_fast (const char *image_path, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | aspose::ocr::page_fast_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_settings (const char *image_path, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Optical character recognition image from file with recognition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_settings_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Optical character recognition image from file with recognition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_tiff (const char *image_path, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Optical character recognition image from file with recognition settings Allowed formats is multi-page TIFF, TIF. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::pages_multi (const char *path_to_recognize, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Batch text recognition in several images packed in ZIP archive or images from folder Internal archives and folders are not supported Only PNG, JPG, BMP internal images are used for recognition from ZIP archive or from folder. | |
DLL_PUBLIC size_t | aspose::ocr::pages_multi_array (const char **files, size_t files_number, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Recognizes multiple images from vector. | |
DLL_PUBLIC size_t | aspose::ocr::pages_multi_array_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Recognizes multiple images from vector. | |
DLL_PUBLIC size_t | aspose::ocr::page_from_uri (const char *uri, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Optical character recognition image from uri with reconition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux) | |
DLL_PUBLIC void | aspose::ocr::page_save (const char *image_path, const char *save_path, RecognitionSettings settings) |
Optical character recognition image from file with reconition settings. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. Saves the document in a plain text, PDF or Microsoft Word Document. | |
DLL_PUBLIC size_t | aspose::ocr::page_all (const char *image_path, wchar_t *buffer, size_t buffer_size, bool correct_skew) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_all_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, bool correct_skew) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_rect (const char *image_path, wchar_t *buffer, size_t buffer_size, int x, int y, int w, int h) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. Skew alignment does not occur. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_rect_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t *buffer, size_t buffer_size, int x, int y, int w, int h) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. Skew alignment does not occur. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_abc (const char *image_path, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_abc_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_abc_all (const char *image_path, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet, bool correct_skew) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Only allowed characters from the alphabet are recognized. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_abc_all_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet, bool correct_skew) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Only allowed characters from the alphabet are recognized. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_rect_abc (const char *image_path, wchar_t *buffer, size_t buffer_size, int x, int y, int w, int h, const wchar_t *const alphabet) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Only allowed characters from the alphabet are recognized. Skew alignment does not occur. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_rect_abc_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t *buffer, size_t buffer_size, int x, int y, int w, int h, const wchar_t *const alphabet) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Only allowed characters from the alphabet are recognized. Skew alignment does not occur. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | aspose::ocr::page_characters_choices (const char *image_path, wchar_t buffer[][6], size_t buffer_size, RecognitionSettings settings) |
A set of characters found by the recognition algorithm and arranged in descending order of probability. | |
DLL_PUBLIC size_t | aspose::ocr::page_characters_choices_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t buffer[][6], size_t buffer_size, RecognitionSettings settings) |
A set of characters found by the recognition algorithm and arranged in descending order of probability. | |
DLL_PUBLIC void | aspose::ocr::preprocess_page_and_save (const char *image_path, const char *save_image_path, filter_operation *filters, size_t filters_number) |
Use image preprocessing to improve the accuracy of OCR. Create an array of filters that will be applied to the input image in the order you specify. example to create filters: filter_operation f[4]; f[0] = (OCR_IMG_Resize(1000, 1000)); f[1] = (OCR_IMG_Scale(0.3)); f[2] = (OCR_IMG_Invert()); f[3] = (OCR_IMG_Binarize()); You don't need all of them. Set only what you need. | |
DLL_PUBLIC void | aspose::ocr::preprocess_page_and_save_from_raw_bytes (const ImageDescriptor &descriptor, const char *save_image_path, filter_operation *filters, size_t filters_number) |
Use image preprocessing to improve the accuracy of OCR. Create an array of filters that will be applied to the input image in the order you specify. example to create filters: filter_operation f[4]; f[0] = (OCR_IMG_Resize(1000, 1000)); f[1] = (OCR_IMG_Scale(0.3)); f[2] = (OCR_IMG_Invert()); f[3] = (OCR_IMG_Binarize()); You don't need all of them. Set only what you need. | |
DLL_PUBLIC size_t | aspose::ocr::line (const char *image_path, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image with one text line. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters. | |
DLL_PUBLIC size_t | aspose::ocr::line_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image with one text line. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters. | |
DLL_PUBLIC size_t | aspose::ocr::line_abc (const char *image_path, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet) |
Optical character recognition image with one text line. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters. | |
DLL_PUBLIC size_t | aspose::ocr::line_abc_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet) |
Optical character recognition image with one text line. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters. | |
DLL_PUBLIC void | aspose::ocr::set_license (const char *licenseFullPath) |
Set license to library. License is XML file. | |
DLL_PUBLIC bool | aspose::ocr::get_state () |
Check license. | |
DLL_PUBLIC double | aspose::ocr::get_skew (const char *image_path) |
Returns the skew angle in degrees. | |
DLL_PUBLIC double | aspose::ocr::get_skew_from_raw_bytes (const ImageDescriptor &descriptor) |
Returns the skew angle in degrees. | |
DLL_PUBLIC double | aspose::ocr::get_skew_from_uri (const char *uri) |
Returns the skew angle in degrees. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux) | |
DLL_PUBLIC size_t | aspose::ocr::get_rectangles_number (const char *image_path, areas_type type, bool all_image) |
Detects the number of text areas in the image. Automatic image skew correction is not applied. | |
DLL_PUBLIC size_t | aspose::ocr::get_rectangles_number_from_raw_bytes (const ImageDescriptor &descriptor, areas_type type, bool all_image) |
Detects the number of text areas in the image. Automatic image skew correction is not applied. | |
DLL_PUBLIC size_t | aspose::ocr::get_rectangles_number_from_uri (const char *uri, areas_type type, bool all_image) |
Detects the number of text areas in the image. Automatic image skew correction is not applied. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux) | |
DLL_PUBLIC size_t | aspose::ocr::get_rectangles (const char *image_path, areas_type type, bool all_image, rect *buffer, size_t buffer_size) |
Detects the text areas in the image. Automatic image skew correction is not applied. | |
DLL_PUBLIC size_t | aspose::ocr::get_rectangles_from_raw_bytes (const ImageDescriptor &descriptor, areas_type type, bool all_image, rect *buffer, size_t buffer_size) |
Detects the text areas in the image. Automatic image skew correction is not applied. | |
DLL_PUBLIC size_t | aspose::ocr::get_rectangles_from_uri (const char *uri, areas_type type, bool all_image, rect *buffer, size_t buffer_size) |
Detects the text areas in the image. Automatic image skew correction is not applied. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux) | |
DLL_PUBLIC size_t | aspose::ocr::recognize_receipt (const char *filePath, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Recognizes a special type of image - cash receipts Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC void | asposeocr_set_progress_tracker (void(*pt)(const AsposeOCRProgress &progress)) |
Set user specified function, that can help to track recognize progress. | |
DLL_PUBLIC void | asposeocr_set_log_settings (const AsposeOCRLogSettings &log_settings) |
Set log settings and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC int | asposeocr_get_allowed_thread_number () |
A function for getting information about the number of threads that will be involved in recognition. | |
DLL_PUBLIC void | asposeocr_set_allowed_thread_number (int amount) |
Function for setting the number of threads that will participate in recognition. | |
DLL_PUBLIC AsposeOCRRecognitionResult | asposeocr_recognize (AsposeOCRInput *descriptors, size_t descriptors_amount, const RecognitionSettings &settings) |
Optical character recognition image with automatic detection of text areas Allowed formats: 1) Images PNG, JPG, BMP, TIFF from file system 2) ZIP archive or images from folder in file system Internal archives and folders are not supported Only PNG, JPG, BMP, TIFF internal images are used for recognition from ZIP archive or from folder 3) Images PNG, JPG, BMP from URI. | |
DLL_PUBLIC AsposeOCRRecognitionResult | asposeocr_detect_defects (AsposeOCRInput *descriptors, size_t descriptors_amount, unsigned int defects=defect_type::ASPOSE_OCR_DETECT_ALL) |
DLL_PUBLIC AsposeOCRRecognitionResult | asposeocr_fast_recognize (AsposeOCRInput *descriptors, size_t descriptors_amount) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC wchar_t * | asposeocr_serialize_result (const AsposeOCRRecognitionResult &recognition_result, size_t &output_buffer_size, const export_format &format=export_format::text) |
Prepare a recognition result in awailable output formats Allowed formats: text, json, xml. | |
DLL_PUBLIC void | asposeocr_free_result (AsposeOCRRecognitionResult &result) |
Releases the memory allocated by the asposeocr_recognize method. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page (const char *image_path, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_fast (const char *image_path, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_fast_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_settings (const char *image_path, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Optical character recognition image from file with reconition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_settings_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Optical character recognition image from file with reconition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_tiff (const char *image_path, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Optical character recognition image from file with recognition settings Allowed formats is multi-page TIFF, TIF. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_pages_multi (const char *folder_path, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Batch text recognition in several images packed in ZIP archive or images from folder Internal archives and folders are not supported Only PNG, JPG, BMP internal images are used for recognition from ZIP archive or from folder. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_from_uri (const char *uri, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Optical character recognition image from uri Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux) | |
DLL_PUBLIC void | asposeocr_page_save (const char *image_path, const char *save_path, RecognitionSettings settings) |
Optical character recognition image from file with reconition settings. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. Saves the document in a plain text, PDF or Microsoft Word Document. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_all (const char *image_path, wchar_t *buffer, size_t buffer_size, bool correct_skew) |
Optical character recognition image without automatic detection of text areas. Get all image as text area. Correct skew of the text according to parameter. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_all_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, bool correct_skew) |
Optical character recognition image without automatic detection of text areas. Get all image as text area. Correct skew of the text according to parameter. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_rect (const char *image_path, wchar_t *buffer, size_t buffer_size, int x, int y, int w, int h) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. Skew alignment does not occur. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_rect_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t *buffer, size_t buffer_size, int x, int y, int w, int h) |
Optical character recognition image in the defined rectangle. Buffer allocated by the caller. Skew alignment does not occur. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_abc (const char *image_path, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_abc_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_abc_all (const char *image_path, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet, bool correct_skew) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Only allowed characters from the alphabet are recognized. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_abc_all_from_raw_bytes (ImageDescriptor *descriptors, size_t descriptors_size, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet, bool correct_skew) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Only allowed characters from the alphabet are recognized. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_rect_abc (const char *image_path, wchar_t *buffer, size_t buffer_size, int x, int y, int w, int h, const wchar_t *const alphabet) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Skew alignment does not occur. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DEPRECATED DLL_PUBLIC size_t | asposeocr_page_rect_abc_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t *buffer, size_t buffer_size, int x, int y, int w, int h, const wchar_t *const alphabet) |
Optical character recognition image in the defined rectangle. Skew alignment does not occur. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC size_t | asposeocr_page_characters_choices (const char *image_path, wchar_t buffer[][6], size_t buffer_size, RecognitionSettings settings) |
A set of characters found by the recognition algorithm and arranged in descending order of probability. | |
DLL_PUBLIC size_t | asposeocr_page_characters_choices_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t buffer[][6], size_t buffer_size, RecognitionSettings settings) |
A set of characters found by the recognition algorithm and arranged in descending order of probability. | |
DLL_PUBLIC void | asposeocr_preprocess_page_and_save (const char *image_path, const char *save_image_path, custom_preprocessing_filters filters) |
Use image preprocessing to improve the accuracy of OCR. Create a vector of filters that will be applied to the input image in the order you specify. example to create filters: custom_preprocessing_filters filters; filters.filter_3 = OCR_IMG_PREPROCESS_INVERT; filters.filter_4 = OCR_IMG_PREPROCESS_THRESHOLD(20); filters.filter_3 = OCR_IMG_PREPROCESS_BINARIZE; filters.filter_1 = OCR_IMG_PREPROCESS_RESIZE(1000, 1000); filters.filter_2 = OCR_IMG_PREPROCESS_SCALE(0.3); filters.filter_6 = OCR_IMG_PREPROCESS_DILATE; filters.filter_7 = OCR_IMG_PREPROCESS_ROTATE(-20); filters.filter_8 = OCR_IMG_PREPROCESS_GRAYSCALE; You don't need all of them. Set only what you need. | |
DLL_PUBLIC size_t | asposeocr_line (const char *image_path, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image with one text line. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters. | |
DLL_PUBLIC size_t | asposeocr_line_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t *buffer, size_t buffer_size) |
Optical character recognition image with one text line. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters. | |
DLL_PUBLIC size_t | asposeocr_line_abc (const char *image_path, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet) |
Optical character recognition image with one text line. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters. | |
DLL_PUBLIC size_t | asposeocr_line_abc_from_raw_bytes (const ImageDescriptor &descriptor, wchar_t *buffer, size_t buffer_size, const wchar_t *const alphabet) |
Optical character recognition image with one text line. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters. | |
DLL_PUBLIC void | asposeocr_set_license (const char *licenseFullPath) |
Set license to library. License is XML file. | |
DLL_PUBLIC bool | asposeocr_get_state () |
Check license. | |
DLL_PUBLIC double | asposeocr_get_skew (const char *image_path) |
Returns the skew angle in degrees. | |
DLL_PUBLIC double | asposeocr_get_skew_from_raw_bytes (const ImageDescriptor &descriptor) |
Returns the skew angle in degrees. | |
DLL_PUBLIC double | asposeocr_get_skew_from_uri (const char *uri) |
Returns the skew angle in degrees. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux) | |
DLL_PUBLIC size_t | asposeocr_get_rectangles_number (const char *image_path, areas_type type, bool all_image) |
Detects the number of text areas in the image. Automatic image skew correction is not applied. | |
DLL_PUBLIC size_t | asposeocr_get_rectangles_number_from_raw_bytes (const ImageDescriptor &descriptor, areas_type type, bool all_image) |
Detects the number of text areas in the image. Automatic image skew correction is not applied. | |
DLL_PUBLIC size_t | asposeocr_get_rectangles_number_from_uri (const char *uri, areas_type type, bool all_image) |
Detects the number of text areas in the image. Automatic image skew correction is not applied. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux) | |
DLL_PUBLIC size_t | asposeocr_get_rectangles (const char *image_path, areas_type type, bool all_image, rect *buffer, size_t buffer_size) |
Detects the text areas in the image. Automatic image skew correction is not applied. | |
DLL_PUBLIC size_t | asposeocr_get_rectangles_from_raw_bytes (const ImageDescriptor &descriptor, areas_type type, bool all_image, rect *buffer, size_t buffer_size) |
Detects the text areas in the image. Automatic image skew correction is not applied. | |
DLL_PUBLIC size_t | asposeocr_get_rectangles_from_uri (const char *uri, areas_type type, bool all_image, rect *buffer, size_t buffer_size) |
Detects the text areas in the image. Automatic image skew correction is not applied. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux) | |
DLL_PUBLIC size_t | asposeocr_recognize_receipt (const char *image_path, wchar_t *buffer, size_t buffer_size, RecognitionSettings settings) |
Recognizes a special type of image - cash receipts Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. | |
DLL_PUBLIC AsposeOCRRecognitionResult | asposeocr_recognize_vehicle_license_plate (const AsposeOCRInput *input, size_t input_amount, const RecognitionSettings &settings) |
Recognizes a special type of image - car number. Allowed formats: 1) Images PNG, JPG, BMP, TIFF from file system. 2) ZIP archive or images from folder in file system. Internal archives and folders are not supported Only PNG, JPG, BMP, TIFF internal images are used for recognition from ZIP archive or from folder. 3) Images PNG, JPG, BMP from URI. | |
DLL_PUBLIC AsposeOCRRecognitionResult | asposeocr_recognize_passport (const AsposeOCRInput *input_array, size_t input_size, const RecognitionSettings &settings) |
Recognizes a special type of image - passports. Allowed formats: 1) Images PNG, JPG, BMP, TIFF from file system. 2) ZIP archive or images from folder in file system. Internal archives and folders are not supported Only PNG, JPG, BMP, TIFF internal images are used for recognition from ZIP archive or from folder. 3) Images PNG, JPG, BMP from URI. | |
DLL_PUBLIC AsposeOCRRecognitionResult asposeocr_detect_defects | ( | AsposeOCRInput * | descriptors, |
size_t | descriptors_amount, | ||
unsigned int | defects = defect_type::ASPOSE_OCR_DETECT_ALL |
||
) |
DLL_PUBLIC AsposeOCRRecognitionResult asposeocr_fast_recognize | ( | AsposeOCRInput * | descriptors, |
size_t | descriptors_amount | ||
) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | Image descriptors array. |
descriptors_amount | Size of allocated descriptors. |
///
DLL_PUBLIC void asposeocr_free_result | ( | AsposeOCRRecognitionResult & | result | ) |
Releases the memory allocated by the asposeocr_recognize method.
recognition_result | Recognition result as a AsposeOCRRecognitionResult structure created by asposeocr_recognize method |
DLL_PUBLIC int asposeocr_get_allowed_thread_number | ( | ) |
A function for getting information about the number of threads that will be involved in recognition.
DLL_PUBLIC size_t asposeocr_get_rectangles | ( | const char * | image_path, |
areas_type | type, | ||
bool | all_image, | ||
rect * | buffer, | ||
size_t | buffer_size | ||
) |
Detects the text areas in the image. Automatic image skew correction is not applied.
image_path | Full path to image. |
type | Determinates wich rectangles to get - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
buffer | Buffer allocated by the caller. The size should be taken from asposeocr_get_rectangles_amount method. |
buffer_size | Size of the buffer allocated by the caller as the number of rect structures. |
DLL_PUBLIC size_t asposeocr_get_rectangles_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
areas_type | type, | ||
bool | all_image, | ||
rect * | buffer, | ||
size_t | buffer_size | ||
) |
Detects the text areas in the image. Automatic image skew correction is not applied.
descriptor | Image descriptor. |
type | Determinates wich rectangles to get - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
buffer | Buffer allocated by the caller. The size should be taken from asposeocr_get_rectangles_amount method. |
buffer_size | Size of the buffer allocated by the caller as the number of rect structures. |
DLL_PUBLIC size_t asposeocr_get_rectangles_from_uri | ( | const char * | uri, |
areas_type | type, | ||
bool | all_image, | ||
rect * | buffer, | ||
size_t | buffer_size | ||
) |
Detects the text areas in the image. Automatic image skew correction is not applied. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux)
uri | Full uri to image. |
type | Determinates wich rectangles to get - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
buffer | Buffer allocated by the caller. The size should be taken from asposeocr_get_rectangles_amount method. |
buffer_size | Size of the buffer allocated by the caller as the number of rect structures. The size should be taken from asposeocr_get_rectangles_amount method. |
DLL_PUBLIC size_t asposeocr_get_rectangles_number | ( | const char * | image_path, |
areas_type | type, | ||
bool | all_image | ||
) |
Detects the number of text areas in the image. Automatic image skew correction is not applied.
image_path | Full path to image. |
type | Determinates wich rectangles to calculate - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
DLL_PUBLIC size_t asposeocr_get_rectangles_number_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
areas_type | type, | ||
bool | all_image | ||
) |
Detects the number of text areas in the image. Automatic image skew correction is not applied.
descriptor | Image descriptor. |
type | Determinates wich rectangles to calculate - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
DLL_PUBLIC size_t asposeocr_get_rectangles_number_from_uri | ( | const char * | uri, |
areas_type | type, | ||
bool | all_image | ||
) |
Detects the number of text areas in the image. Automatic image skew correction is not applied. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux)
uri | Full uri to image. |
type | Determinates wich rectangles to calculate - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
DLL_PUBLIC double asposeocr_get_skew | ( | const char * | image_path | ) |
Returns the skew angle in degrees.
image_path | Full path to image. |
DLL_PUBLIC double asposeocr_get_skew_from_raw_bytes | ( | const ImageDescriptor & | descriptor | ) |
Returns the skew angle in degrees.
descriptor | Image descriptor. |
DLL_PUBLIC double asposeocr_get_skew_from_uri | ( | const char * | uri | ) |
Returns the skew angle in degrees. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux)
uri | Full uri to image. |
DLL_PUBLIC bool asposeocr_get_state | ( | ) |
Check license.
DLL_PUBLIC size_t asposeocr_line | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image with one text line. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters.
image_path | Full path to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DLL_PUBLIC size_t asposeocr_line_abc | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image with one text line. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters.
image_path | Full path to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
DLL_PUBLIC size_t asposeocr_line_abc_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image with one text line. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
DLL_PUBLIC size_t asposeocr_line_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image with one text line. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_abc | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_abc_all | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet, | ||
bool | correct_skew | ||
) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Only allowed characters from the alphabet are recognized. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
correct_skew | Remove skew image. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_abc_all_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet, | ||
bool | correct_skew | ||
) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Only allowed characters from the alphabet are recognized. If the buffer is null, the function returns the required buffer size.
descriptors | Image descriptors array. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
correct_skew | Remove skew image. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_abc_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | Image descriptors array. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_all | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
bool | correct_skew | ||
) |
Optical character recognition image without automatic detection of text areas. Get all image as text area. Correct skew of the text according to parameter. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
correct_skew | Remove skew image. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_all_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
bool | correct_skew | ||
) |
Optical character recognition image without automatic detection of text areas. Get all image as text area. Correct skew of the text according to parameter. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | Image descriptors array. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
correct_skew | Remove skew image. |
DLL_PUBLIC size_t asposeocr_page_characters_choices | ( | const char * | image_path, |
wchar_t | buffer[][6], | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
A set of characters found by the recognition algorithm and arranged in descending order of probability.
The array of symbols char with the maximum probability and alternatives.
image_path | Full path to the image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition. |
DLL_PUBLIC size_t asposeocr_page_characters_choices_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t | buffer[][6], | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
A set of characters found by the recognition algorithm and arranged in descending order of probability.
The array of symbols char with the maximum probability and alternatives.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_fast | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_fast_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | Image descriptors array. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | Image descriptors array. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_from_uri | ( | const char * | uri, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from uri Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux)
uri | Full uri to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition: allows to set automatic detection of text areas - all_image(default false), allows to set automatic skew correction of the text - correct_skew(default true), allows to set customer skew correction of the text - skew(default 0), allows to set rectangles in pixels for recognize - rectangles array, allows to set characters from the alphabet to recognition - alphabet(default nullptr), allows to set language - language_alphabet (default language::none), allows to set threshold value for image binarization - threshold_value (default is 0, automatically calculated). |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_rect | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
int | x, | ||
int | y, | ||
int | w, | ||
int | h | ||
) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. Skew alignment does not occur. If the buffer is null, the function returns the required buffer size.
image_path | Full path to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
x | Left rectangle in pixels. |
y | Top rectangle in pixels. |
w | Rectangle width in pixels. |
h | Rectangle height in pixels. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_rect_abc | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
int | x, | ||
int | y, | ||
int | w, | ||
int | h, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Skew alignment does not occur. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | Full path to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
x | Left rectangle in pixels. |
y | Top rectangle in pixels. |
w | Rectangle width in pixels. |
h | Rectangle height in pixels. |
alphabet | Allowed symbols. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_rect_abc_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
int | x, | ||
int | y, | ||
int | w, | ||
int | h, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image in the defined rectangle. Skew alignment does not occur. Only allowed characters from the alphabet are recognized. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
x | Left rectangle in pixels. |
y | Top rectangle in pixels. |
w | Rectangle width in pixels. |
h | Rectangle height in pixels. |
alphabet | Allowed symbols. |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_rect_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
int | x, | ||
int | y, | ||
int | w, | ||
int | h | ||
) |
Optical character recognition image in the defined rectangle. Buffer allocated by the caller. Skew alignment does not occur. If the buffer is null, the function returns the required buffer size.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
x | Left rectangle in pixels. |
y | Top rectangle in pixels. |
w | Rectangle width in pixels. |
h | Rectangle height in pixels. |
DLL_PUBLIC void asposeocr_page_save | ( | const char * | image_path, |
const char * | save_path, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from file with reconition settings. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. Saves the document in a plain text, PDF or Microsoft Word Document.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
save_path | Filename with a path for saving recognition result in the selected format. |
settings | parameters for recognition: allows to set automatic detection of text areas - all_image(default false), allows to set automatic skew correction of the text - correct_skew(default true), allows to set customer skew correction of the text - skew(default 0), allows to set rectangles in pixels for recognize - rectangles array, allows to set characters from the alphabet to recognition - alphabet(default nullptr), allows to set language - language_alphabet (default language::none), allows to set threshold value for image binarization - threshold_value (default is 0, automatically calculated), allows to set format for file - save_format (default file_format:: txt). |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_settings | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from file with reconition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition: allows to set automatic detection of text areas - all_image(default false), allows to set automatic skew correction of the text - correct_skew(default true), allows to set customer skew correction of the text - skew(default 0), allows to set rectangles in pixels for recognize - rectangles array, allows to set characters from the alphabet to recognition - alphabet(default nullptr), allows to set language - language_alphabet (default language::none), allows to set threshold value for image binarization - threshold_value (default is 0, automatically calculated). |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_settings_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from file with reconition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | Image descriptors array. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition: allows to set automatic detection of text areas - all_image(default false), allows to set automatic skew correction of the text - correct_skew(default true), allows to set customer skew correction of the text - skew(default 0), allows to set rectangles in pixels for recognize - rectangles array, allows to set characters from the alphabet to recognition - alphabet(default nullptr), allows to set language - language_alphabet (default language::none), allows to set threshold value for image binarization - threshold_value (default is 0, automatically calculated). |
DEPRECATED DLL_PUBLIC size_t asposeocr_page_tiff | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from file with recognition settings Allowed formats is multi-page TIFF, TIF. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple TIFF (TIF) images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition
|
DEPRECATED DLL_PUBLIC size_t asposeocr_pages_multi | ( | const char * | folder_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Batch text recognition in several images packed in ZIP archive or images from folder Internal archives and folders are not supported Only PNG, JPG, BMP internal images are used for recognition from ZIP archive or from folder.
folder_path | full path to the zip archive (with .zip name) or to the folder with images |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition: allows to set automatic detection of text areas - all_image(default false), allows to set automatic skew correction of the text - correct_skew(default true), allows to set customer skew correction of the text - skew(default 0), allows to set rectangles in pixels for recognize - rectangles array, allows to set characters from the alphabet to recognition - alphabet(default nullptr), allows to set language - language_alphabet (default language::all), allows to set threshold value for image binarization - threshold_value (default is 0, automatically calculated). |
DLL_PUBLIC void asposeocr_preprocess_page_and_save | ( | const char * | image_path, |
const char * | save_image_path, | ||
custom_preprocessing_filters | filters | ||
) |
Use image preprocessing to improve the accuracy of OCR. Create a vector of filters that will be applied to the input image in the order you specify. example to create filters: custom_preprocessing_filters filters; filters.filter_3 = OCR_IMG_PREPROCESS_INVERT; filters.filter_4 = OCR_IMG_PREPROCESS_THRESHOLD(20); filters.filter_3 = OCR_IMG_PREPROCESS_BINARIZE; filters.filter_1 = OCR_IMG_PREPROCESS_RESIZE(1000, 1000); filters.filter_2 = OCR_IMG_PREPROCESS_SCALE(0.3); filters.filter_6 = OCR_IMG_PREPROCESS_DILATE; filters.filter_7 = OCR_IMG_PREPROCESS_ROTATE(-20); filters.filter_8 = OCR_IMG_PREPROCESS_GRAYSCALE; You don't need all of them. Set only what you need.
image_path | Full path to the image. |
save_image_path | Full path to the output filtered image. |
filters | Image optimization filterscustom_preprocessing_filters. |
DLL_PUBLIC AsposeOCRRecognitionResult asposeocr_recognize | ( | AsposeOCRInput * | descriptors, |
size_t | descriptors_amount, | ||
const RecognitionSettings & | settings | ||
) |
Optical character recognition image with automatic detection of text areas Allowed formats: 1) Images PNG, JPG, BMP, TIFF from file system 2) ZIP archive or images from folder in file system Internal archives and folders are not supported Only PNG, JPG, BMP, TIFF internal images are used for recognition from ZIP archive or from folder 3) Images PNG, JPG, BMP from URI.
descriptors | Image descriptors array. |
descriptors_amount | Size of allocated descriptors. |
settings | parameters for recognition: allows to set automatic detection of text areas - all_image(default false), allows to set automatic skew correction of the text - correct_skew(default true), allows to set customer skew correction of the text - skew(default 0), allows to set rectangles in pixels for recognize - rectangles array, allows to set characters from the alphabet to recognition - alphabet(default nullptr), allows to set language - language_alphabet (default language::none), allows to set threshold value for image binarization - threshold_value (default is 0, automatically calculated). |
DLL_PUBLIC AsposeOCRRecognitionResult asposeocr_recognize_passport | ( | const AsposeOCRInput * | input_array, |
size_t | input_size, | ||
const RecognitionSettings & | settings | ||
) |
Recognizes a special type of image - passports. Allowed formats: 1) Images PNG, JPG, BMP, TIFF from file system. 2) ZIP archive or images from folder in file system. Internal archives and folders are not supported Only PNG, JPG, BMP, TIFF internal images are used for recognition from ZIP archive or from folder. 3) Images PNG, JPG, BMP from URI.
input | Image descriptors array. |
input_amount | Buffer allocated by the caller. |
settings | parameters for recognition Awailable settings fields:
|
DLL_PUBLIC size_t asposeocr_recognize_receipt | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Recognizes a special type of image - cash receipts Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition
|
DLL_PUBLIC AsposeOCRRecognitionResult asposeocr_recognize_vehicle_license_plate | ( | const AsposeOCRInput * | input, |
size_t | input_amount, | ||
const RecognitionSettings & | settings | ||
) |
Recognizes a special type of image - car number. Allowed formats: 1) Images PNG, JPG, BMP, TIFF from file system. 2) ZIP archive or images from folder in file system. Internal archives and folders are not supported Only PNG, JPG, BMP, TIFF internal images are used for recognition from ZIP archive or from folder. 3) Images PNG, JPG, BMP from URI.
input | Image descriptors array. |
input_amount | Buffer allocated by the caller. |
settings | parameters for recognition Awailable settings fields:
|
DLL_PUBLIC wchar_t * asposeocr_serialize_result | ( | const AsposeOCRRecognitionResult & | recognition_result, |
size_t & | output_buffer_size, | ||
const export_format & | format = export_format::text |
||
) |
Prepare a recognition result in awailable output formats Allowed formats: text, json, xml.
recognition_result | Recognition result as a AsposeOCRRecognitionResult structure. |
output_buffer_size | Size of allocated buffer. Filled by called method. |
format | Output format descriptor |
DLL_PUBLIC void asposeocr_set_allowed_thread_number | ( | int | amount | ) |
Function for setting the number of threads that will participate in recognition.
amount | Number of threads to set. |
DLL_PUBLIC void asposeocr_set_license | ( | const char * | licenseFullPath | ) |
Set license to library. License is XML file.
licenseFullPath | Full path to license file. |
DLL_PUBLIC void asposeocr_set_log_settings | ( | const AsposeOCRLogSettings & | log_settings | ) |
Set log settings and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
log_settings | Log settings structure. |
DLL_PUBLIC void asposeocr_set_progress_tracker | ( | void(*)(const AsposeOCRProgress &progress) | pt | ) |
Set user specified function, that can help to track recognize progress.
pt | Pointer to user specified function. |
DLL_PUBLIC size_t aspose::ocr::get_rectangles | ( | const char * | image_path, |
areas_type | type, | ||
bool | all_image, | ||
rect * | buffer, | ||
size_t | buffer_size | ||
) |
Detects the text areas in the image. Automatic image skew correction is not applied.
image_path | Full path to image. |
type | Determinates wich rectangles to get - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
buffer | Buffer allocated by the caller. The size should be taken from asposeocr_get_rectangles_amount method. |
buffer_size | Size of the buffer allocated by the caller as the number of rect structures. |
DLL_PUBLIC size_t aspose::ocr::get_rectangles_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
areas_type | type, | ||
bool | all_image, | ||
rect * | buffer, | ||
size_t | buffer_size | ||
) |
Detects the text areas in the image. Automatic image skew correction is not applied.
descriptor | Image descriptor. |
type | Determinates wich rectangles to get - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
buffer | Buffer allocated by the caller. The size should be taken from asposeocr_get_rectangles_amount method. |
buffer_size | Size of the buffer allocated by the caller as the number of rect structures. |
DLL_PUBLIC size_t aspose::ocr::get_rectangles_from_uri | ( | const char * | uri, |
areas_type | type, | ||
bool | all_image, | ||
rect * | buffer, | ||
size_t | buffer_size | ||
) |
Detects the text areas in the image. Automatic image skew correction is not applied. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux)
uri | Full uri to image. |
type | Determinates wich rectangles to get - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
buffer | Buffer allocated by the caller. The size should be taken from asposeocr_get_rectangles_amount method. |
buffer_size | Size of the buffer allocated by the caller as the number of rect structures. The size should be taken from asposeocr_get_rectangles_amount method. |
DLL_PUBLIC size_t aspose::ocr::get_rectangles_number | ( | const char * | image_path, |
areas_type | type, | ||
bool | all_image | ||
) |
Detects the number of text areas in the image. Automatic image skew correction is not applied.
image_path | Full path to image. |
type | Determinates wich rectangles to calculate - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
DLL_PUBLIC size_t aspose::ocr::get_rectangles_number_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
areas_type | type, | ||
bool | all_image | ||
) |
Detects the number of text areas in the image. Automatic image skew correction is not applied.
descriptor | Image descriptor. |
type | Determinates wich rectangles to calculate - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
DLL_PUBLIC size_t aspose::ocr::get_rectangles_number_from_uri | ( | const char * | uri, |
areas_type | type, | ||
bool | all_image | ||
) |
Detects the number of text areas in the image. Automatic image skew correction is not applied. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux)
uri | Full uri to image. |
type | Determinates wich rectangles to calculate - line or paragraphs. |
all_image | Disabled (false) by default. Turning on means recognizing the image as a single area (switch off automatic text paragraphs detection). |
DLL_PUBLIC double aspose::ocr::get_skew | ( | const char * | image_path | ) |
Returns the skew angle in degrees.
image_path | Full path to image. |
DLL_PUBLIC double aspose::ocr::get_skew_from_raw_bytes | ( | const ImageDescriptor & | descriptor | ) |
Returns the skew angle in degrees.
descriptor | Image descriptor. |
DLL_PUBLIC double aspose::ocr::get_skew_from_uri | ( | const char * | uri | ) |
Returns the skew angle in degrees. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux)
uri | Full uri to image. |
DLL_PUBLIC bool aspose::ocr::get_state | ( | ) |
Check license.
DLL_PUBLIC size_t aspose::ocr::line | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image with one text line. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters.
image_path | Full path to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DLL_PUBLIC size_t aspose::ocr::line_abc | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image with one text line. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters.
image_path | Full path to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
DLL_PUBLIC size_t aspose::ocr::line_abc_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image with one text line. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
DLL_PUBLIC size_t aspose::ocr::line_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image with one text line. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size in wide characters.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DLL_PUBLIC size_t aspose::ocr::page | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DLL_PUBLIC size_t aspose::ocr::page_abc | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
DLL_PUBLIC size_t aspose::ocr::page_abc_all | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet, | ||
bool | correct_skew | ||
) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Only allowed characters from the alphabet are recognized. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
correct_skew | Remove skew image. |
DLL_PUBLIC size_t aspose::ocr::page_abc_all_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet, | ||
bool | correct_skew | ||
) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Only allowed characters from the alphabet are recognized. If the buffer is null, the function returns the required buffer size.
descriptor | Image descriptors array. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
correct_skew | Remove skew image. |
DLL_PUBLIC size_t aspose::ocr::page_abc_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Only allowed characters from the alphabet are recognized. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptor | Image descriptor. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
alphabet | Allowed symbols. |
DLL_PUBLIC size_t aspose::ocr::page_all | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
bool | correct_skew | ||
) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
correct_skew | Remove skew image. |
DLL_PUBLIC size_t aspose::ocr::page_all_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
bool | correct_skew | ||
) |
Optical character recognition image without automatic detection of text areas Get all image as text area. Correct skew of the text according to parameter. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | An array of ImageDescriptor. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
correct_skew | Remove skew image. |
DLL_PUBLIC size_t aspose::ocr::page_characters_choices | ( | const char * | image_path, |
wchar_t | buffer[][6], | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
A set of characters found by the recognition algorithm and arranged in descending order of probability.
The array of symbols char with the maximum probability and alternatives.
image_path | Full path to the image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition. |
DLL_PUBLIC size_t aspose::ocr::page_characters_choices_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t | buffer[][6], | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
A set of characters found by the recognition algorithm and arranged in descending order of probability.
The array of symbols char with the maximum probability and alternatives.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition. |
DEPRECATED DLL_PUBLIC size_t aspose::ocr::page_fast | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DEPRECATED DLL_PUBLIC size_t aspose::ocr::page_fast_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image. Doesn't use automatic text areas detecting and skew correction. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | An array of ImageDescriptor. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DLL_PUBLIC size_t aspose::ocr::page_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size | ||
) |
Optical character recognition image with automatic detection of text areas and detecting, correct skew of the text. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | An array of ImageDescriptor. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
DLL_PUBLIC size_t aspose::ocr::page_from_uri | ( | const char * | uri, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from uri with reconition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/). (Linux)
uri | Full uri to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition
|
DLL_PUBLIC size_t aspose::ocr::page_rect | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
int | x, | ||
int | y, | ||
int | w, | ||
int | h | ||
) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. Skew alignment does not occur. If the buffer is null, the function returns the required buffer size.
image_path | Full path to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
x | Left rectangle in pixels. |
y | Top rectangle in pixels. |
w | Rectangle width in pixels. |
h | Rectangle height in pixels. |
DLL_PUBLIC size_t aspose::ocr::page_rect_abc | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
int | x, | ||
int | y, | ||
int | w, | ||
int | h, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Only allowed characters from the alphabet are recognized. Skew alignment does not occur. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | Full path to image. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
x | Left rectangle in pixels. |
y | Top rectangle in pixels. |
w | Rectangle width in pixels. |
h | Rectangle height in pixels. |
alphabet | Allowed symbols. |
DLL_PUBLIC size_t aspose::ocr::page_rect_abc_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
int | x, | ||
int | y, | ||
int | w, | ||
int | h, | ||
const wchar_t *const | alphabet | ||
) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Only allowed characters from the alphabet are recognized. Skew alignment does not occur. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
x | Left rectangle in pixels. |
y | Top rectangle in pixels. |
w | Rectangle width in pixels. |
h | Rectangle height in pixels. |
alphabet | Allowed symbols. |
DLL_PUBLIC size_t aspose::ocr::page_rect_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
int | x, | ||
int | y, | ||
int | w, | ||
int | h | ||
) |
Optical character recognition image in the defined rectangle. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. Skew alignment does not occur. If the buffer is null, the function returns the required buffer size.
descriptor | Image descriptor. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
x | Left rectangle in pixels. |
y | Top rectangle in pixels. |
w | Rectangle width in pixels. |
h | Rectangle height in pixels. |
DLL_PUBLIC void aspose::ocr::page_save | ( | const char * | image_path, |
const char * | save_path, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from file with reconition settings. Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size. Saves the document in a plain text, PDF or Microsoft Word Document.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
save_path | Filename with a path for saving recognition result in the selected format. |
settings | parameters for recognition: allows to set automatic detection of text areas - all_image(default false), allows to set automatic skew correction of the text - correct_skew(default true), allows to set customer skew correction of the text - skew(default 0), allows to set rectangles in pixels for recognize - rectangles array, allows to set characters from the alphabet to recognition - alphabet(default nullptr), allows to set language - language_alphabet (default language::none), allows to set threshold value for image binarization - threshold_value (default is 0, automatically calculated), allows to set format for file - save_format (default file_format:: txt). |
DLL_PUBLIC size_t aspose::ocr::page_settings | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from file with recognition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition
|
DLL_PUBLIC size_t aspose::ocr::page_settings_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from file with recognition settings Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
descriptors | An array of ImageDescriptor. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition
|
DLL_PUBLIC size_t aspose::ocr::page_tiff | ( | const char * | image_path, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Optical character recognition image from file with recognition settings Allowed formats is multi-page TIFF, TIF. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple TIFF (TIF) images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition
|
DLL_PUBLIC size_t aspose::ocr::pages_multi | ( | const char * | path_to_recognize, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Batch text recognition in several images packed in ZIP archive or images from folder Internal archives and folders are not supported Only PNG, JPG, BMP internal images are used for recognition from ZIP archive or from folder.
path_to_recognize | full path to the zip archive (with .zip name) or to the folder with images |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition Allows to set automatic detection of text areas - all_image(default false) Allows to set automatic skew correction of the text - correct_skew(default true) Allows to set customer skew correction of the text - skew(default 0) Allows to set rectangles in pixels for recognize - rectangles array Allows to set characters from the alphabet to recognition - alphabet(default nullptr) Allows to set language - language_alphabet (default language::all) |
DLL_PUBLIC size_t aspose::ocr::pages_multi_array | ( | const char ** | files, |
size_t | files_number, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Recognizes multiple images from vector.
Archives and folders are not supported. Max amount of processed images is 20. Supports GIF, PNG, JPEG, BMP.
files | The pointer on the two-dimensional array with full paths to the images. |
files_number | The number of files for recognition.The size of the first dimension of the files array. |
buffer | Buffer allocated by the caller to save result from all images recognition. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | Recognition settings. |
DLL_PUBLIC size_t aspose::ocr::pages_multi_array_from_raw_bytes | ( | ImageDescriptor * | descriptors, |
size_t | descriptors_size, | ||
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Recognizes multiple images from vector.
Archives and folders are not supported. Max amount of processed images is 20. Supports GIF, PNG, JPEG, BMP.
descriptors | An array of ImageDescriptor. |
descriptors_size | Size of allocated descriptors. |
buffer | Buffer allocated by the caller to save result from all images recognition. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | Recognition settings. |
DLL_PUBLIC void aspose::ocr::preprocess_page_and_save | ( | const char * | image_path, |
const char * | save_image_path, | ||
filter_operation * | filters, | ||
size_t | filters_number | ||
) |
Use image preprocessing to improve the accuracy of OCR. Create an array of filters that will be applied to the input image in the order you specify. example to create filters: filter_operation f[4]; f[0] = (OCR_IMG_Resize(1000, 1000)); f[1] = (OCR_IMG_Scale(0.3)); f[2] = (OCR_IMG_Invert()); f[3] = (OCR_IMG_Binarize()); You don't need all of them. Set only what you need.
image_path | Full path to the image. |
save_image_path | Full path to the output filtered image. |
filters | Image optimization filtersfilter_operation.Pointer on the array. |
filters_number | Number of the filters in the array. |
DLL_PUBLIC void aspose::ocr::preprocess_page_and_save_from_raw_bytes | ( | const ImageDescriptor & | descriptor, |
const char * | save_image_path, | ||
filter_operation * | filters, | ||
size_t | filters_number | ||
) |
Use image preprocessing to improve the accuracy of OCR. Create an array of filters that will be applied to the input image in the order you specify. example to create filters: filter_operation f[4]; f[0] = (OCR_IMG_Resize(1000, 1000)); f[1] = (OCR_IMG_Scale(0.3)); f[2] = (OCR_IMG_Invert()); f[3] = (OCR_IMG_Binarize()); You don't need all of them. Set only what you need.
descriptor | Image descriptor. |
save_image_path | Full path to the output filtered image. |
filters | Image optimization filtersfilter_operation.Pointer on the array. |
filters_number | Number of the filters in the array. |
DLL_PUBLIC size_t aspose::ocr::recognize_receipt | ( | const char * | filePath, |
wchar_t * | buffer, | ||
size_t | buffer_size, | ||
RecognitionSettings | settings | ||
) |
Recognizes a special type of image - cash receipts Allowed formats is PNG, JPG, BMP. Buffer allocated by the caller. If the buffer is null, the function returns the required buffer size.
image_path | The full path to the image or the paths for multiple images separated by a semicolon. |
buffer | Buffer allocated by the caller. |
buffer_size | Size of buffer allocated by the caller in wchar_t characters. |
settings | parameters for recognition
|
DLL_PUBLIC void aspose::ocr::set_license | ( | const char * | licenseFullPath | ) |
Set license to library. License is XML file.
licenseFullPath | Full path to license file. |