L_MICRDetectionEXT

#include "l_bitmap.h"

L_LTIMGCOR_API L_INT L_MICRDetectionEXT(pBitmap, pOptions, uFlags)

Function to detect MICR zones on a bitmap given a specified set of options.

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

Functions

Topics

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 22.0.2021.9.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C API Help
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.