Jonathan Osuch wrote:
I don't see this line twice in gifview.c in any of the four different sources I have. Although it doesn't always matter, it is helpful to know which source you are looking at and where did you get it. 8-))
Because this guy here [points at himself] forgot to switch his brains on :-( The two lines are *not* identical (the second one manages the appearance of a possible local color table). Source: 2002sync.zip patched up to v20.3, but gifview.c hasn't changed since v20.2. Line 143: planes = (buffer[10] & 0x0F) + 1; Line 263: planes = (buffer[8] & 0x0F) + 1; In the first case the next bit after the global color palette size info signals a sorted palette and should be excluded by the mask. In the second case the next two bits after the local color palette size info are reserved and should be excluded by the mask, too (although I doubt there ever will be a new GIF version which will use this field :-)). Regards (still feeling stupid), Gerald