LTwain::GetScanConfigs

Summary

Gets the default scan configurations for the given transfer mode, buffer iteration and bits per pixel.

This function is available in the Document/Medical Toolkits.

Syntax

#include "ltwrappr.h"

virtual L_INT LTwain::GetScanConfigs(nBitsPerPixel, uTransferMode, nBufferIteration, ppFastConfig, uStructSize, pnFastConfigCount)

Parameters

L_INT nBitsPerPixel

The number of bits per pixel for which to get the default scan configurations.

L_UINT uTransferMode

Transfer mode for which to get the default scan configurations.

Value Meaning
LTWAIN_FILE_MODE [0x001] Use File transfer mode
LTWAIN_BUFFER_MODE [0x002] Use Memory transfer mode
LTWAIN_NATIVE_MODE [0x004] Use Native transfer mode

L_INT nBufferIteration

Number used to determine the number of memory configurations that will be tested. This function uses this number to determine which default scan configurations to get.

pFASTCONFIG *ppFastConfig

Address of a pointer to a FASTCONFIG structure. This function will automatically allocate an array of FASTCONFIG structures using the total number of scan configurations. This array will be updated with the scan configurations retrieved based on the specified bits per pixel, transfer mode and number of buffers.

L_UINT uStructSize

Size of the FASTCONFIG structure, in bytes, for versioning. Use sizeof(FASTCONFIG).

L_INT *pnFastConfigCount

Pointer to an integer to be updated with number of scan configurations in ppFastConfig.

Returns

Value Meaning
SUCCESS The function was successful.
< 1 An error occurred. Refer to Return Codes.

Comments

If uTransferMode is LTWAIN_NATIVE_MODE, this function will use the value of nBitsPerPixel to determine which scan configurations to get.

If uTransferMode is LTWAIN_BUFFER_MODE, this function will use both nBitsPerPixel and nBufferIteration to determine which scan configurations to get.

If uTransferMode is LTWAIN_FILE_MODE, this function will use the value of nBitsPerPixel to determine which scan configurations to get.

This function allocates storage for the array of scan configurations in ppFastConfig. When this storage is no longer needed, you must free the storage by calling LTwain::FreeScanConfig.

Required DLLs and Libraries

See Also

Functions

Topics

Example

For an example, refer to LTwain::FindFastConfig.

Help Version 22.0.2022.12.7
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS TWAIN C++ Class Library Help
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.