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

Comparing rxvt-unicode/src/rxvtimg.h (file contents):
Revision 1.27 by root, Sat Jun 9 10:21:19 2012 UTC vs.
Revision 1.28 by root, Sat Jun 9 11:13:14 2012 UTC

5 #define HAVE_IMG 1 5 #define HAVE_IMG 1
6#endif 6#endif
7 7
8#if HAVE_IMG 8#if HAVE_IMG
9 9
10#define float_to_component(d) (uint16_t)((d) * 65535.99) 10#define float_to_component(d) (int32_t)((d) * 65535.99)
11 11
12#include <X11/extensions/Xrender.h> 12#include <X11/extensions/Xrender.h>
13 13
14class rxvt_img 14class rxvt_img
15{ 15{
67 void unshare (); // prepare for write 67 void unshare (); // prepare for write
68 void fill (const rxvt_color &c); 68 void fill (const rxvt_color &c);
69 //void linear_gradient (const XLinearGradient *gradient, const XFixed *stops, const XRenderColor *colors, int nstops); 69 //void linear_gradient (const XLinearGradient *gradient, const XFixed *stops, const XRenderColor *colors, int nstops);
70 //void radial_gradient (const XRadialGradient *gradient, const XFixed *stops, const XRenderColor *colors, int nstops); 70 //void radial_gradient (const XRadialGradient *gradient, const XFixed *stops, const XRenderColor *colors, int nstops);
71 //void conical_gradient (const XConicalGradient *gradient, const XFixed *stops, const XRenderColor *colors, int nstops); 71 //void conical_gradient (const XConicalGradient *gradient, const XFixed *stops, const XRenderColor *colors, int nstops);
72 void brightness (uint16_t r, uint16_t g, uint16_t b, uint16_t a); 72 void brightness (int32_t r, int32_t g, int32_t b, int32_t a);
73 void contrast (uint16_t r, uint16_t g, uint16_t b, uint16_t a); 73 void contrast (int32_t r, int32_t g, int32_t b, int32_t a);
74 74
75 void brightness (double r, double g, double b, double a = 1.) 75 void brightness (double r, double g, double b, double a = 1.)
76 { 76 {
77 brightness (float_to_component (r), 77 brightness (float_to_component (r),
78 float_to_component (g), 78 float_to_component (g),

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines