]>
Commit | Line | Data |
---|---|---|
3bdc2f5c KK |
1 | diff -Nur xbmc-9.11.orig/xbmc/lib/cximage-6.0/CxImage/ximapng.cpp xbmc-9.11/xbmc/lib/cximage-6.0/CxImage/ximapng.cpp |
2 | --- xbmc-9.11.orig/xbmc/lib/cximage-6.0/CxImage/ximapng.cpp 2008-07-18 23:40:53.000000000 +0300 | |
3 | +++ xbmc-9.11/xbmc/lib/cximage-6.0/CxImage/ximapng.cpp 2010-01-20 21:55:11.000000000 +0200 | |
4 | @@ -142,9 +142,9 @@ | |
5 | if (info_ptr->num_trans!=0){ //palette transparency | |
6 | if (info_ptr->num_trans==1){ | |
7 | if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE){ | |
8 | - info.nBkgndIndex = info_ptr->trans_values.index; | |
9 | + info.nBkgndIndex = info_ptr->trans_color.index; | |
10 | } else{ | |
11 | - info.nBkgndIndex = info_ptr->trans_values.gray>>nshift; | |
12 | + info.nBkgndIndex = info_ptr->trans_color.gray>>nshift; | |
13 | } | |
14 | } | |
15 | if (info_ptr->num_trans>1){ | |
16 | @@ -152,7 +152,7 @@ | |
17 | if (pal){ | |
18 | DWORD ip; | |
19 | for (ip=0;ip<min(head.biClrUsed,(unsigned long)info_ptr->num_trans);ip++) | |
20 | - pal[ip].rgbReserved=info_ptr->trans[ip]; | |
21 | + pal[ip].rgbReserved=info_ptr->trans_alpha[ip]; | |
22 | for (ip=info_ptr->num_trans;ip<head.biClrUsed;ip++){ | |
23 | pal[ip].rgbReserved=255; | |
24 | } | |
25 | @@ -166,9 +166,9 @@ | |
26 | int num_trans; | |
27 | png_color_16 *image_background; | |
28 | if (png_get_tRNS(png_ptr, info_ptr, &trans, &num_trans, &image_background)){ | |
29 | - info.nBkgndColor.rgbRed = (BYTE)(info_ptr->trans_values.red>>nshift); | |
30 | - info.nBkgndColor.rgbGreen = (BYTE)(info_ptr->trans_values.green>>nshift); | |
31 | - info.nBkgndColor.rgbBlue = (BYTE)(info_ptr->trans_values.blue>>nshift); | |
32 | + info.nBkgndColor.rgbRed = (BYTE)(info_ptr->trans_color.red>>nshift); | |
33 | + info.nBkgndColor.rgbGreen = (BYTE)(info_ptr->trans_color.green>>nshift); | |
34 | + info.nBkgndColor.rgbBlue = (BYTE)(info_ptr->trans_color.blue>>nshift); | |
35 | info.nBkgndColor.rgbReserved = 0; | |
36 | info.nBkgndIndex = 0; | |
37 | } | |
38 | @@ -417,12 +417,12 @@ | |
39 | if (info.nBkgndIndex >= 0){ | |
40 | info_ptr->num_trans = 1; | |
41 | info_ptr->valid |= PNG_INFO_tRNS; | |
42 | - info_ptr->trans = trans; | |
43 | - info_ptr->trans_values.index = (BYTE)info.nBkgndIndex; | |
44 | - info_ptr->trans_values.red = tc.rgbRed; | |
45 | - info_ptr->trans_values.green = tc.rgbGreen; | |
46 | - info_ptr->trans_values.blue = tc.rgbBlue; | |
47 | - info_ptr->trans_values.gray = info_ptr->trans_values.index; | |
48 | + info_ptr->trans_alpha = trans; | |
49 | + info_ptr->trans_color.index = (BYTE)info.nBkgndIndex; | |
50 | + info_ptr->trans_color.red = tc.rgbRed; | |
51 | + info_ptr->trans_color.green = tc.rgbGreen; | |
52 | + info_ptr->trans_color.blue = tc.rgbBlue; | |
53 | + info_ptr->trans_color.gray = info_ptr->trans_color.index; | |
54 | ||
55 | // the transparency indexes start from 0 for non grayscale palette | |
56 | if (!bGrayScale && head.biClrUsed && info.nBkgndIndex) | |
57 | @@ -443,7 +443,7 @@ | |
58 | trans[ip]=GetPaletteColor((BYTE)ip).rgbReserved; | |
59 | info_ptr->num_trans = (WORD)nc; | |
60 | info_ptr->valid |= PNG_INFO_tRNS; | |
61 | - info_ptr->trans = trans; | |
62 | + info_ptr->trans_alpha = trans; | |
63 | } | |
64 | ||
65 | // copy the palette colors | |
66 | diff -Nur xbmc-9.11.orig/xbmc/screensavers/rsxs-0.9/src/pngimage.cc xbmc-9.11/xbmc/screensavers/rsxs-0.9/src/pngimage.cc | |
67 | --- xbmc-9.11.orig/xbmc/screensavers/rsxs-0.9/src/pngimage.cc 2008-07-30 23:35:38.000000000 +0300 | |
68 | +++ xbmc-9.11/xbmc/screensavers/rsxs-0.9/src/pngimage.cc 2010-01-20 22:21:01.000000000 +0200 | |
69 | @@ -65,7 +65,7 @@ | |
70 | (png_get_color_type(png, pngInfo) == PNG_COLOR_TYPE_GRAY) && | |
71 | png_get_bit_depth(png, pngInfo) < 8 | |
72 | ) | |
73 | - png_set_gray_1_2_4_to_8(png); | |
74 | + png_set_expand_gray_1_2_4_to_8(png); | |
75 | if (png_get_valid(png, pngInfo, PNG_INFO_tRNS)) | |
76 | png_set_tRNS_to_alpha(png); | |
77 | if (fullColor) | |
78 | diff -Nur xbmc-9.11.orig/xbmc/visualizations/Goom/goom2k4-0/src/pngload.c xbmc-9.11/xbmc/visualizations/Goom/goom2k4-0/src/pngload.c | |
79 | --- xbmc-9.11.orig/xbmc/visualizations/Goom/goom2k4-0/src/pngload.c 2008-08-04 05:05:51.000000000 +0300 | |
80 | +++ xbmc-9.11/xbmc/visualizations/Goom/goom2k4-0/src/pngload.c 2010-01-20 22:16:23.000000000 +0200 | |
81 | @@ -94,7 +94,7 @@ | |
82 | png_set_palette_to_rgb (png_ptr); | |
83 | ||
84 | if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) | |
85 | - png_set_gray_1_2_4_to_8 (png_ptr); | |
86 | + png_set_expand_gray_1_2_4_to_8 (png_ptr); | |
87 | else if (color_type == PNG_COLOR_TYPE_GRAY || | |
88 | color_type == PNG_COLOR_TYPE_GRAY_ALPHA) | |
89 | png_set_gray_to_rgb (png_ptr); |