00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #ifndef GIF_H
00015 #define GIF_H
00016
00017 #include "il_internal.h"
00018
00019 #define GIF87A 87
00020 #define GIF89A 89
00021
00022 #ifdef _WIN32
00023 #pragma pack(push, gif_struct, 1)
00024 #endif
00025 typedef struct GIFHEAD
00026 {
00027 char Sig[6];
00028 ILushort Width;
00029 ILushort Height;
00030 ILubyte ColourInfo;
00031 ILubyte Background;
00032 ILubyte Aspect;
00033 } IL_PACKSTRUCT GIFHEAD;
00034
00035 typedef struct IMAGEDESC
00036 {
00037 ILubyte Separator;
00038 ILushort OffX;
00039 ILushort OffY;
00040 ILushort Width;
00041 ILushort Height;
00042 ILubyte ImageInfo;
00043 } IL_PACKSTRUCT IMAGEDESC;
00044
00045 typedef struct GFXCONTROL
00046 {
00047 ILubyte Size;
00048 ILubyte Packed;
00049 ILushort Delay;
00050 ILubyte Transparent;
00051 ILubyte Terminator;
00052 ILboolean Used;
00053
00054
00055 } IL_PACKSTRUCT GFXCONTROL;
00056 #ifdef _WIN32
00057 #pragma pack(pop, gif_struct)
00058 #endif
00059
00060
00061 ILboolean iLoadGifInternal(void);
00062 ILboolean ilLoadGifF(ILHANDLE File);
00063 ILboolean iIsValidGif(void);
00064 ILboolean iGetPalette(ILubyte Info, ILpal *Pal, ILboolean UsePrevPal, ILimage *PrevImage);
00065 ILboolean GetImages(ILpal *GlobalPal, GIFHEAD *GifHead);
00066 ILboolean SkipExtensions(GFXCONTROL *Gfx);
00067 ILboolean GifGetData(ILimage *Image, ILubyte *Data, ILuint ImageSize, ILuint Width, ILuint Height, ILuint Stride, ILuint PalOffset, GFXCONTROL *Gfx);
00068 ILboolean RemoveInterlace(ILimage *image);
00069 ILboolean ConvertTransparent(ILimage *Image, ILubyte TransColour);
00070
00071 #endif//GIF_H