L_MICRDetection

#include "Ltimgcor.h"

L_LTIMGCOR_API L_INT L_MICRDetection(pBitmap, Inrc, Outrc, Flags)

BITMAPHANDLE* pBitmap;

pointer to the bitmap handle

L_RECT Inrc;

structure that represents the area to be searched

L_RECT* Outrc;

a pointer to an L_RECT structure that represents the location of the detected MICR zone

L_UINT Flags;

Flags

Automatically detects Magnetic Ink Character Recognition (MICR) zones in a document image.

Parameter

Description

pBitmap

Pointer to the bitmap handle that contains the MICR code.

Inrc

Represents the area to be searched.

Outrc

Represents the location of the MICR zone that was detected.

Flags

Reserved for future use.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

This function searches a given L_RECT zone in a document image for a MICR zone.

This function processes only the region specified by the InRect parameter. 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

LTIMGCOR

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

Platforms

Win32, x64, Linux.

See Also

Functions:

L_MRZDetection

Topics:

Raster Image Functions: Image Analysis

Processing an Image
Raster Image Functions: Document Imaging

Example

This example loads a bitmap and applies MICR detection filter.

L_INT MICRDetectionFilterBitmapExample(L_VOID) 
{ 
   L_INT nRet; 
   BITMAPHANDLE LeadBitmap;   /* Bitmap handle to hold the loaded image. */ 
   /* Load the bitmap, keeping the bits per pixel of the file */ 
   nRet = L_LoadBitmap (MAKE_IMAGE_PATH(TEXT("MICR_SAMPLE.tif")), &LeadBitmap, sizeof(BITMAPHANDLE), 0, ORDER_BGR, NULL, NULL); 
   if(nRet !=SUCCESS) 
      return nRet; 
 
   /* Apply a MICR detection filter and return the location of the MICR code in Outrc rect*/ 
   L_RECT Inrc  = { 0, 0, 0, 0 } ; 
   L_RECT Outrc = { 0, 0, 0, 0 } ; 
 
   nRet = L_MICRDetection(&LeadBitmap, Inrc, &Outrc, 0); 
 
   //free bitmap 
   if(LeadBitmap.Flags.Allocated)   
      L_FreeBitmap(&LeadBitmap); 
 
   return nRet; 
} 

Help Version 20.0.2018.7.30
Products | Support | Contact Us | Copyright Notices
© 1991-2018 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C API Help