Welcome Guest! To enable all features, please Login or Register.

Notification

Icon
Error

Options
View
Last Go to last post Unread Go to first unread post
#1 Posted : Tuesday, November 16, 2010 4:11:38 AM(UTC)

Stefan  
Stefan

Groups: Registered
Posts: 1


Hello everyone,

I've been fighting with the Twain library for 2 weeks now and finally made it up to a point where I can scan 100-120PPM on our Kodak scanners.

Now I'm trying to get the images informations right and to avoid making wrong assumptions, I'm willing to retrieve the current page number and the image side while scanning.

At the moment I'm using TwainSession.Acquire to get my images but in the EventArgs I don't see anything about the current page being scanned and the side of the image.
There is an empty variable, but I don't know if it serves any purpose.

Is there a possibility, through capabilities or something to find what is the page number and side which belongs to the current image?

In other scanning programs the info seems to exist. Or is this info calculated knowing that the scan is dual-stream and double-sided?
I'm wondering how you'd be able to keep up with that knowing that Remove Blank options can cut documents in half. It would be impossible to keep a correct page count.

Thanks in advance for any info/pointers.

Regards,
 

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

#2 Posted : Friday, November 19, 2010 5:23:25 AM(UTC)

Walter  
Walter

Groups: Tech Support
Posts: 366

Thanks: 1 times
Was thanked: 4 time(s) in 4 post(s)

Hello Stefan,

What version of LEADTOOLS are you using?

There isn't anything in the TwainSession that would tell you what the current page is that is being scanned. It is expected that the application would keep track of the number of pages scanned through the AcquirePage event handler.

Regarding being able to retreive the side of the image, this you should know from the capabilities available by the scanner, and through the pages you've scanned. If the scanner supports TwainCapabilityType.Duplex(CAP_DUPLEX) and TwainCapabilityType.DuplexEnabled (CAP_DUPLEXENALBED) is set to true, then you would know that all of the odd pages scanned would be the front-side and the even pages would be the back-side. If this capability isn't available or isn't enabled, then all pages would be the front-side of the page.

To your point about the removal of blank pages, I agree that it would be the problem if the scanner will automatically remove pages that are blank. In order to keep a proper count these options should be turned off. With LEADTOOLS, we have a BlankPageDetectorCommand that you could also run on the image to determine if there's anything on the page or not. If there isn't anything on the page, then you could choose to discard it and not display it to the user. LEADTOOLS is on the application side of this, so if the scanner doesn't send the image information to the application, we would never know the device didn't send an image that was supposed to be received. This is why such options (if the exist with the scanner), should be disabled in this case. This can be done with ICAP_AUTODISCARDBLANKPAGES and specifying TWBP_DISABLE.
Walter Bates
Senior Support Engineer
LEAD Technologies, Inc.
LEAD Logo
 
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2024, Yet Another Forum.NET
This page was generated in 0.105 seconds.