--- parser3/src/lib/gd/gifio.C 2005/08/09 08:14:50 1.3 +++ parser3/src/lib/gd/gifio.C 2017/02/07 22:00:38 1.7 @@ -1,7 +1,7 @@ /** @file Parser: image manipulations impl2. - Copyright (c) 2001-2005 ArtLebedev Group (http://www.artlebedev.com) + Copyright (c) 2001-2017 Art. Lebedev Studio (http://www.artlebedev.com) Author: Alexandr Petrosian (http://paf.design.ru) based on: gd @@ -35,10 +35,10 @@ ** CompuServe Incorporated. */ -static const char * const IDENT_GIFIO_C="$Date: 2005/08/09 08:14:50 $"; - #include "gif.h" +volatile const char * IDENT_GIFIO_C="$Id: gifio.C,v 1.7 2017/02/07 22:00:38 moko Exp $"; + static int colorstobpp(int colors); gdBuf gdImage::Gif() @@ -774,9 +774,6 @@ bool gdImage::CreateFromGif(FILE *fd) { int imageNumber; int BitPixel; - int ColorResolution; - int Background; - int AspectRatio; int Transparent =(-1); unsigned char buf[16]; unsigned char c; @@ -806,9 +803,6 @@ bool gdImage::CreateFromGif(FILE *fd) return false; } BitPixel = 2<<(buf[4]&0x07); - ColorResolution =(int)(((buf[4]&0x70)>>3)+1); - Background = buf[5]; - AspectRatio = buf[6]; if(BitSet(buf[4], LOCALCOLORMAP)) { /* Global Colormap */ if(ReadColorMap(fd, BitPixel, ColorMap)) { @@ -909,17 +903,13 @@ int gdImage::DoExtension(FILE *fd, int l switch(label) { case 0xf9: { /* Graphic Control Extension */ (void) GetDataBlock(fd,(unsigned char*) buf); - Gif89 gif89 = { -1, -1, -1, 0 }; // PAF:huh? - gif89.disposal =(buf[0] >> 2) & 0x7; - gif89.inputFlag =(buf[0] >> 1) & 0x1; - gif89.delayTime = LM_to_uint(buf[1],buf[2]); if((buf[0] & 0x1) != 0) *Transparent = buf[3]; while(GetDataBlock(fd,(unsigned char*) buf) != 0) ; return FALSE; - } + } default: break; }