Data capture, character recognition OCR ICR OMR CHR BCR, image processing, forms data capture, document indexing, automatic data extraction Data capture, character recognition OCR ICR OMR CHR BCR, image processing, forms data capture, document indexing, automatic data extraction
Recogniform Black Border Removal SDK

Recogniform Black Border Removal SDK

This black border removal sdk allows the automatic black border detection and removal in monochrome or gray-scale images. The black border is produced in the images acquired by scanners when paper size is smaller than scanning area or in images acquired from microfilm, microfiches and aperture-cards. Removing the border from the images is a very important pre-processing step that improves the compression rate, reducing file size, and the visualization aspect.
Other libraries usually allow you to detect and remove black border only in monochrome images, while Recogniform library allows user to remove black border both in gray-scales and in color images!
Before the removal of the dark edge
After the removal of the dark edge

After the removal of the dark edge
Before the removal of the dark edge
Black border removal can be carried out in two distinct ways: either cropping the images or white colouring the border area. In the first way the image size is reduced to the effective size of paper, in the second way the image size still remains the same and the image is surrounded by a white extra area. The operation is performed in two steps: the border detection and the border elimination using one of the two available strategies.

You can also set:

  • Black Percentage, a parameter indicating the minimum percentage of black pixels a line has to contain to be considered dark and, potentially, part of the border.
You have to supply a DIB (Device Independent Bitmap) in input to the process obviously .

The border identification and the border removal procedures are fast and accurate.
For testing this library you can download a demo application (400 KB) that allows you to use this function on your TIF images: please give us your feedback and your comments after the test !
Here is source code in Microsoft Visual C++ of a sample application using the black border removal library:

#include "stdafx.h"
#include "stdio.h"
#include "recoautocrop.c"

int APIENTRY WinMain(HINSTANCE hInstance,
                     HINSTANCE hPrevInstance,
                     LPSTR     lpCmdLine,
                     int       nCmdShow)
{ 	

 // Load dynamically the library
 LoadAutoCropLibrary();

 // Init the AUTOCROP session
 int Session= AUTOCROP_Init("demo", "demo");

 long hBitmap = 0;

 // Check if a DIB is available in clipboard
 bool bAvail= IsClipboardFormatAvailable(CF_DIB);

 if (bAvail)
  {

   // Open the Clipboard
   ::OpenClipboard(NULL);
	
   // Retrieve the DIB from clipboard 
   hBitmap = (long) GetClipboardData(CF_DIB);

   RECT Page;
	
   // Detect the black border on the DIB
   AUTOCROP_FindBlackBorder(Session, (long) hBitmap, 99.5, &Page);

   // Remove the black border resizing the DIB
   AUTOCROP_Crop(Session, (long) hBitmap, Page);

   // or you could remove the black border blanking it
   //AUTOCROP_Clean(Session, (long) hBitmap, Page);
 
   ::EmptyClipboard();

   // Set the cropped DIB to clipboard
   SetClipboardData(CF_DIB, (void*)hBitmap);

   // Close the Clipboard	
   ::CloseClipboard();

   char  buffer[200];

   sprintf( buffer, "Black Border Removed !
     You can paste the processed image in your application...");

   // Show the result
   MessageBox(NULL, buffer, "RESULT", MB_OK);
	

  }
  // Show an error message
  else MessageBox(NULL, "Unable to paste DIB", "ERROR", MB_OK);

 // Close the session
 AUTOCROP_Done(Session);

 // Unload the library	
 FreeAutoCropLibrary();

return 0;
}
                                            
Evaluation version
Through the download section you can download an evaluation version of this product.


Looking a solution ready to use capable of processing any type of documents and forms, printed or handwritten, structured (fixed layout) or unstructured (variable layout)? Choose Recogniform Reader!
To more information about Recogniform Black Border Removal SDK and our solution for data capture and image processing, you can send us a email to informazioni@recogniform.it or fill the below form.


Company
Title
First Name
Last Name
Address
Zip Code
State
Country
Phone
Fax
E-mail
Message

Taking note of Information of the policy of personal data (D. Lgs 30 june 2003 n.196 and subsequent amendment and additions), click on the "OK" button i consent to collect, hold, process, communicate, and if appropriate, discontinue the treatment/s of personal data that concern me, for the purposes specified in the policy.

   
  • Recogniform Black Border Removal SDK - Purchase

    Despeckle Black Border Removal - Royalties Free

    The Black Border Removal SDK is royaltes-free which you can deploy and use the software that integrates the capabilities up to 1000 computers without additional cost. Using this SDK require the license agreement subscription whereby order evasion does not require physical shipment. If you want to deploy over 1000 runtime licenses you need to purchase multiple licenses of the product.
    € 599,00 + VAT