Optimizes a supported image format buffer using the passed optimization options.
Parameters
- codecs
- The Leadtools.Codecs.RasterCodecs object used internally in the optimization operation.
- buffer
- The original image buffer in memory as System.IntPtr array. The image format in memory should be one of the following supported formats:
- RasterImageFormat.Jpeg, Bits per pixel: 8 for grayscale, 24 for color.
- RasterImageFormat.Jpeg411, Bits per pixel: 8 for grayscale, 24 for color.
- RasterImageFormat.Jpeg422, Bits per pixel: 8 for grayscale, 24 for color.
- RasterImageFormat.ExifJpeg411, Bits per pixel: 24 (color only).
- RasterImageFormat.ExifJpeg422, Bits per pixel: 24 (color only).
- RasterImageFormat.Gif, Bits per pixel: 1, 2, 3, 4, 5, 6, 7, and 8.
- RasterImageFormat.Png, Bits per pixel: 1, 4, 8, 24, 32, 48, and 64.
- RasterImageFormat.Bmp, Bits per pixel: 1, 4, 8, 16, 24, and 32.
- RasterImageFormat.BmpRle, Bits per pixel: 4, and 8.
- length
- The size, in bytes, of the parameter in memory.
- options
- The options used in the optimization process.
- progressCallback
- Optional callback function that provides information about the progress of the optimization process.
Return Value
A
Leadtools.RasterNativeBuffer structure that contains the image optimized buffer in memory.
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2