L_MICRDetectionEXT

Summary

Detects Magnetic Ink Character Recognition (MICR) zones on a bitmap, using a specified set of options.

Syntax

#include "l_bitmap.h"

L_LTIMGCOR_API L_INT L_MICRDetectionEXT(pBitmap, pOptions, uFlags)

Parameters

BITMAPHANDLE *pBitmap

The reference to the bitmap.

pMICRCODEDETECTOROPTIONS pOptions

The specified options passed to the detection.

L_UINT uFlags

Reserved for future use. Pass 0.

Returns

Value Meaning
SUCCESS The function was successful.
< 1 An error occurred. Refer to Return Codes.

Comments

Specify the rcInputROI in the MICRCODEDETECTOROPTIONS structure to detect the MICR zone.

This function processes only the region specified by the rcInputROI. It does not support regions.

This function supports 8-, 12-, and 16-bit grayscale images and 24- and 32-bit color images.

Required DLLs and Libraries

Platforms

Win32, x64, Linux.

See Also

Example

This example loads a bitmap and applies MICR detection with a specified set of options.

L_INT MICRDetectionEXTBitmapExample(L_VOID) 
{ 
   L_INT nRet; 
   /* Bitmap handle to hold the loaded image. */ 
   BITMAPHANDLE LeadBitmap; 
   MICRCODEDETECTOROPTIONS micrOptions = { 0 }; 
 
   /* Load the bitmap, keeping the bits per pixel of the file */ 
   nRet = L_LoadBitmap(MAKE_IMAGE_PATH(TEXT("bankcheck.jpg")), &LeadBitmap, sizeof(BITMAPHANDLE), 0, ORDER_BGR, NULL, NULL); 
   if (nRet != SUCCESS) 
      return nRet; 
 
   /* Specify the region of interest for the MICR zone. */ 
   micrOptions.uStructSize = sizeof(MICRCODEDETECTOROPTIONS); 
   micrOptions.rcInputROI = { 500, 600, LeadBitmap.Width, LeadBitmap.Height }; 
 
   nRet = L_MICRDetectionEXT(&LeadBitmap, &micrOptions, 0); 
 
   /* Free bitmap. */ 
   if (LeadBitmap.Flags.Allocated) 
      L_FreeBitmap(&LeadBitmap); 
 
   return nRet; 
} 

Help Version 23.0.2024.2.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C API Help

Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.