However, only certain file formats are supported at this time. LEADTOOLS also provides the LFile::TransformFile function for performing lossless flips, rotations and reversals. For more information, refer to Deskewing.įor resizing any kind of bitmap, LBitmapBase::Size and LBitmapBase::SizeInterpolate provides the most up-to-date options, but you may also find the alternative and low-level functions useful. LBitmap::Deskew (Document/Medical only) has special flags that make it possible to straighten bank check images. ![]() For example, LBitmap::Deskew ( Document/Medical) and LBitmap::DeskewExt( Document/Medical) let you automatically straighten and trim scanned documents. Some geometric transformation functions are designed mainly for document imaging. ![]() Geometric transformations include resizing, trimming, rotating, shearing, flipping, or reversing a bitmap. LBitmap::ShiftZeroToNegative gives the user the ability to specify the amount by which to shift the image data, and dictates the minimum and maximum values that are output by the function. LBitmap::ConvertSignedToUnsigned shifts the image data based on internal aspects of the bitmap. To change image data from unsigned to signed, which is often done after applying image processing or analysis functions, there are the following options: (Most image processing functions work only on unsigned data.) When the image processing or analysis is complete, convert the unsigned data back to signed data. ![]() Once signed images have been converted to unsigned images image processing or analysis functions can be performed on the unsigned images. LBitmapBase::ClearNegativePixels sets all negative pixels to 0, therefore creating an unsigned image. This information can be used later, after image processing, to return the image to signed data. LBitmap::ShiftMinimumToZero provides the user with the value by which the image data was shifted. LBitmap::ConvertUnsignedToSigned shifts the image data based on internal aspects of the bitmap. To change image data from signed to unsigned, which is often done before applying image processing or analysis functions, there are the following options: The ability to shift image data back and forth between signed and unsigned is often useful in medical or analytical applications. Converting data from signed to unsigned, and vice versa, will be done by shifting the image data or intensity values by a specific value. Signed image data may contain some negative values. Image data can be changed from signed to unsigned and vice versa. You can also use the low-level LBuffer::ConvertColorSpace function to convert raw data in a buffer from one color-space model to another, including RGB, YUV, CMYK, CMY, YIQ, HSV, and HLS.Ĭhanging the Data Type (Signed / Unsigned) You can use the high-level LBitmap::ColorSeparate and LBitmap::ColorMerge functions to create and merge color separations using a number of color-space models, including RGB, CMYK, CMY, HSV, and HLS. Nevertheless, LEADTOOLS provides functions for other color-space models. Windows always uses the RGB color-space model, and when loading or saving a file, LEADTOOLS converts image data to or from RGB, as necessary. ![]() For a list of these functions, refer to Doing Color Expansion or Reduction. You can change the color resolution (bits per pixel) of an image using a number of high-level and low-level functions. Some low-level functions act on a buffer that you manage, for example when you process data as it is loaded. Most image processing functions act on a bitmap in memory, which means that the changes become permanent when you save the image in a file.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |