Once the user has established a handle to a TWAIN session, the TWAIN source to use for acquiring images should be selected. To determine the TWAIN sources available on the system, LEADTOOLS provides the LTwain::GetSources function. This function enumerates all available TWAIN sources and calls the LTwain::SourceInfoCallBack function for each TWAIN source found.
To select the TWAIN source to use for acquiring images, call the LTwain::SelectSource function.
Each TWAIN source has certain capabilities. The user may wish to alter these capability settings before acquiring images from the TWAIN source. For more information on this, refer to Getting and Setting Capabilities.
LEADTOOLS TWAIN toolkit also provides functions to manage the TWAIN sources installed on the system:
LTwain::SelectSource displays a dialog that lists all available TWAIN sources installed on the system. This dialog lets the user select the TWAIN source he or she wants to use.
LTwain::GetSources function is used to enumerate either all available TWAIN sources, or the currently selected TWAIN source, and retrieve the name of the source(s). The LTwain::SourceInfoCallBack function is called for each TWAIN source enumerated.