[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-devel
Subject: [Patch] Fix wrong color type for RGBA in kfile_png
From: Volker Krause <volker.krause () web ! de>
Date: 2002-08-29 14:12:02
[Download RAW message or body]
Hello,
the attached patch fixes the wrong color type value for RGBA images in the png
file plugin. The correct value is 6 (see PNG spec), but currently 5 is used.
The wrong color type value causes a wrong display of the bit depth as well as
the color type.
Volker Krause
["kfile_png.cpp.diff" (text/x-diff)]
Index: kfile_png.cpp
===================================================================
RCS file: /home/kde/kdegraphics/kfile-plugins/png/kfile_png.cpp,v
retrieving revision 1.14
diff -u -r1.14 kfile_png.cpp
--- kfile_png.cpp 28 Aug 2002 21:23:39 -0000 1.14
+++ kfile_png.cpp 29 Aug 2002 13:52:26 -0000
@@ -62,6 +62,7 @@
I18N_NOOP("RGB"),
I18N_NOOP("Palette"),
I18N_NOOP("Grayscale/Alpha"),
+ I18N_NOOP("Unknown"),
I18N_NOOP("RGB/Alpha")
};
@@ -142,7 +143,7 @@
case 2: bpp *= 3; break; // RGB
case 3: break; // palette
case 4: bpp *= 2; break; // grayscale w. alpha
- case 5: bpp *= 4; break; // RGBA
+ case 6: bpp *= 4; break; // RGBA
default: // we don't get any sensible value here
bpp = 0;
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic