libpng patches must use a -D macro definet to use nwer or older
version alternate!
or this patch must be inplemented outside normal release of qt3.
by example in every specific distribution as Arch do in the kde3
alternate proyect.
On Thu, Apr 28, 2011 at 4:35 PM, Baho Utot
<baho-utot(a)columbus.rr.com>wrote;wrote:
On 04/28/2011 12:49 PM, PICCORO McKAY Lenz
wrote:
> Hi Hello! everyone.
>
> in this fashion API changes these days, I found that debian and
> winbuntu old lasted revisions, has old libpng 1.2, especialy
> lenny with 1.2.22, which means that the patchs for libpng 1.4
> support on qt3 for trinity can make impossible compile into
> Debian squeeze, testing inlcusive, as win-buntu 9.XX, it
> should be modified to use a macro -LIB_PNG_14 or something
> similar .. I do not remember how to work with this but if I
> can do for the weekend..
>
> If some body can do that , please change the patch for use
> optionaly both library versions...
>
> If i can resolve all issues, i do a qt3 3.3.c tar gzipped
> release alternate for ready download in public, for easy acces
> to novice developers
>
> I have libpng 1.4.5-1 installed and this patch for qt3 works
> for me
--- src/kernel/qpngio.cpp.orig 2010-01-16 22:02:41.000000000
+0100 +++ src/kernel/qpngio.cpp 2010-01-16 22:03:56.000000000
+0100 @@ -159,7 +159,7 @@
image.setColor( i, qRgba(c,c,c,0xff) );
}
if ( png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS) ) {
- const int g = info_ptr->trans_values.gray;
+ const int g = info_ptr->trans_color.gray;
if (g < ncols) {
image.setAlphaBuffer(TRUE);
image.setColor(g, image.color(g) & RGB_MASK);
@@ -187,7 +187,7 @@
info_ptr->palette[i].red,
info_ptr->palette[i].green,
info_ptr->palette[i].blue,
- info_ptr->trans[i]
+ info_ptr->trans_alpha[i]
)
);
i++;
@@ -321,9 +321,9 @@
png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS)
if (image.depth()==32 && png_get_valid(png_ptr, info_ptr,
PNG_INFO_tRNS)) {
QRgb trans = 0xFF000000 | qRgb(
- (info_ptr->trans_values.red << 8 >> bit_depth)&0xff,
- (info_ptr->trans_values.green << 8 >>
bit_depth)&0xff,
- (info_ptr->trans_values.blue << 8 >>
bit_depth)&0xff);
+ (info_ptr->trans_color.red << 8 >> bit_depth)&0xff,
+ (info_ptr->trans_color.green << 8 >> bit_depth)&0xff,
+ (info_ptr->trans_color.blue << 8 >> bit_depth)&0xff);
for (uint y=0; y<height; y++) {
for (uint x=0; x<info_ptr->width; x++) {
if (((uint**)jt)[y][x] == trans) {
---------------------------------------------------------------------
To unsubscribe, e-mail:
trinity-devel-unsubscribe(a)lists.pearsoncomputing.net
For additional commands, e-mail:
trinity-devel-help(a)lists.pearsoncomputing.net
Read list messsages on the Web archive:
http://trinity-devel.pearsoncomputing.net/
Please remember not to top-post:
http://trinity.pearsoncomputing.net/mailing_lists/#top-posting