ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/rxvtimg.C
(Generate patch)

Comparing rxvt-unicode/src/rxvtimg.C (file contents):
Revision 1.57 by root, Thu Jun 7 20:32:58 2012 UTC vs.
Revision 1.60 by sf-exg, Fri Jun 8 10:12:45 2012 UTC

13rxvt_img::rxvt_img (const rxvt_img &img) 13rxvt_img::rxvt_img (const rxvt_img &img)
14: s(img.s), x(img.x), y(img.y), w(img.w), h(img.h), format(img.format), repeat(img.repeat), pm(img.pm), ref(img.ref) 14: s(img.s), x(img.x), y(img.y), w(img.w), h(img.h), format(img.format), repeat(img.repeat), pm(img.pm), ref(img.ref)
15{ 15{
16 ++ref->cnt; 16 ++ref->cnt;
17} 17}
18
19#if 0
20rxvt_img::rxvt_img (rxvt_screen *screen, XRenderPictFormat *format, int width, int height, Pixmap pixmap)
21: s(screen), x(0), y(0), w(width), h(height), format(format), repeat(RepeatNormal), shared(false), pm(pixmap)
22{
23}
24#endif
25 18
26rxvt_img * 19rxvt_img *
27rxvt_img::new_from_root (rxvt_screen *s) 20rxvt_img::new_from_root (rxvt_screen *s)
28{ 21{
29 Display *dpy = s->display->dpy; 22 Display *dpy = s->display->dpy;
134 uint32_t v = *(uint32_t *)src; src += 4; 127 uint32_t v = *(uint32_t *)src; src += 4;
135 128
136 if (ecb_big_endian ()) 129 if (ecb_big_endian ())
137 v = ecb_bswap32 (v); 130 v = ecb_bswap32 (v);
138 131
139 v = ecb_rotl32 (v, 8); 132 v = ecb_rotl32 (v, 8); // abgr to bgra
140 133
141 if (!byte_order_mismatch) 134 if (!byte_order_mismatch)
142 v = ecb_bswap32 (v); 135 v = ecb_bswap32 (v);
143 136
144 *dst++ = v; 137 *dst++ = v;
302 295
303 size = rv * 2 + 1; 296 size = rv * 2 + 1;
304 get_gaussian_kernel (rv, size, kernel, params); 297 get_gaussian_kernel (rv, size, kernel, params);
305 ::swap (params[0], params[1]); 298 ::swap (params[0], params[1]);
306 299
307 XRenderSetPictureFilter (dpy, src, FilterConvolution, params, size+2); 300 XRenderSetPictureFilter (dpy, tmp, FilterConvolution, params, size+2);
308 XRenderComposite (dpy, 301 XRenderComposite (dpy,
309 PictOpSrc, 302 PictOpSrc,
310 tmp, 303 tmp,
311 None, 304 None,
312 dst, 305 dst,

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines