Implementing GIF Features

The following features are implemented when loading and saving GIF files:

File Comments

You can get and set comments in GIF files using the L_GetComment, L_SetComment, L_DeleteComment, L_ReadFileComment, and L_ReadFileCommentMemory functions. In these functions, only the CMNT_SZDESC type of comment is supported.

In a multi-page file, these functions reference the last comment encountered before the page specified by the LOADFILEOPTION structure.

Interlaced Files

With an interlaced file, a paint-while-load operation displays the full size of the image as quickly as possible, then fills in the missing rows. For an example of the paint-while-load code, refer to the FILEREADCALLBACK function.

To save a GIF file as an interlaced file, use the SAVEFILEOPTION function to set the ESO_INTERLACED flag before saving the file.

Embedded Text

If plain text is embedded in a GIF file, LEADTOOLS rasterizes the text when loading the file, making the text part of the bitmap.

Animation

To load and play an animated GIF file, you can load a list of bitmaps from the file, then play the list to a target bitmap in a loop that displays each change in the target bitmap. You can also create an animation sequence from scratch and save the bitmaps to create an animated GIF file. For more information, refer to Implementing Animation.

Transparency

When playing an animation, the playback process recognizes the transparent color and the transparency flag specified in the BITMAPHANDLE of each bitmap. The transparent color is loaded from and saved to GIF files. Refer to: Implementing Transparency.

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS Raster Imaging C API Help