DTwainCompressedTransfer::GetBestCompressionType |
Top Previous Next |
Syntax
DTwainCompressionType DTwainCompressedTransfer::GetBestCompressionType( DTwainCompressionType CompType, bool bIsMono = false ) const;
Parameters CompType The general compression type to use when checking for the best compression available.
bIsMono Return the best compression if acquiring to a monochrome image (1 bit-per-pixel).
Return Value Returns the compression type that creates the smallest image size (in bytes)
Comments
The CompType parameter must be one of the following:
The bIsMono parameter should be true if the image acquired will be a 1-bit-per-pixel image. Currently, a value of true for bIsMono is only recognized if the CompType is COMPRESS_TIFF.
An example of usage of this function would be if you want to get the best TIFF compression. A CompType value of COMPRESS_TIFF may return COMPRESS_LZW, COMPRESS_NONE, COMPRESS_GROUP4 (if the bIsMono flag is set to true), etc. |