mirror of https://github.com/GNOME/gimp.git
Bill Skaggs <weskaggs@primate.ucdavis.edu>
* plug-ins/common/tga.c: gracefully handle incorrect alpha info in header; fixes bug #306675.
This commit is contained in:
parent
42ff7f4920
commit
34e144e1eb
|
@ -1,3 +1,8 @@
|
|||
2006-05-19 Bill Skaggs <weskaggs@primate.ucdavis.edu>
|
||||
|
||||
* plug-ins/common/tga.c: gracefully handle incorrect alpha
|
||||
info in header; fixes bug #306675.
|
||||
|
||||
2006-05-19 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* app/core/gimpitem-linked.h: remove enum GimpItemLinkedMask...
|
||||
|
|
|
@ -505,6 +505,10 @@ load_image (const gchar *filename)
|
|||
info.flipHoriz = (header[17] & 0x10) ? 1 : 0;
|
||||
info.flipVert = (header[17] & 0x20) ? 0 : 1;
|
||||
|
||||
/* hack to handle some existing files with incorrect headers, see bug #306675 */
|
||||
if (info.alphaBits == info.bpp)
|
||||
info.alphaBits = 0;
|
||||
|
||||
switch (info.imageType)
|
||||
{
|
||||
case TGA_TYPE_MAPPED:
|
||||
|
|
Loading…
Reference in New Issue