Scanning Documents (C++)

You are here:
< All Topics

This function scans “n” images and creates a set with the scanned images.

SETOFIMG *ScanNImage(int num) 
{
int i; 
SETOFIMG *set; // create an empty set 
set=CreateMultipleImg(); // check for error 
if (set==NULL) return NULL; // Initialize scanning session 
if (ScanInit()) return NULL; 
for(i=0;i<n;i++) 
{
// scan a new image, add it to set and check for error 
if (ScanAndAddImage(set)) 
{
// An error occured 
FreeMultipleImg(set); 
ScanEnd(); 
return NULL;
}
} 
// Terminate scanning session 
ScanEnd(); 
// return the set 
return set;
}
Previous OCR on a Multipage TIFF Image File (C++)
Next SimpleOCR SDK Disclaimer
Table of Contents
Contact Us for FREE Consultation on Your OCR Project
Go to Top