How to Acquire from the TWAIN Source

After the user has established a TWAIN session, selected a TWAIN source, and set the desired capabilities of the TWAIN source, he or she is ready to acquire images or image data from that source. LEADTOOLS provides the following functions for acquiring images and image data from a TWAIN source:

The LTwain::AcquireMulti and LTwain::FastAcquire functions takes an optional parameter a pointer to an LTwain::AcquireCallBack function. This callback function is called twice for each page scanned using the LTwain::AcquireMulti or LTwain::FastAcquire functions. It is called the first time when the Twain source begins scanning the page. It is called the second time when the Twain source has finished scanning the page.

The functions listed above can acquire images in the following transfer modes:

Native

gets the bitmaps being scanned into the memory as a whole.

Memory Buffered

gets images from the source as strips of data. These strips can be merged to get the whole image.

File

gets the images from the source to a disk file.

To stop an acquire process started by the LTwain::Acquire function, call LTwain::CancelAcquire inside the LTwain::BitmapCallBack.

To stop an acquire process started by the LTwain::AcquireMulti or LTwain::FastAcquire functions, call LTwain::CancelAcquire inside the LTwain::AcquireCallBack.

To stop acquire images only from the feeder of the TWAIN source using the LTwain::Acquire function, call the LTwain::StopFeeder within the LTwain::BitmapCallBack function when its fired.

To stop acquire images only from the feeder of the TWAIN source using the LTwain::AcquireMulti or LTwain::FastAcquire functions, call the LTwain::StopFeeder within the LTwain::AcquireCallBack function when its fired.

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS TWAIN C++ Class Library Help