41
40
#define OPAQUE_OPACITY 255
42
41
#define TRANSPARENT_OPACITY 0
45
46
#define INT_MULT(a,b,t) ((t) = (a) * (b) + 0x80, ((((t) >> 8) + (t)) >> 8))
50
#define INT_MULT3(a,b,c,t) ((t) = (a) * (b) * (c) + 0x7F5B, ((((t) >> 7) + (t)) >> 16))
54
/* #define INT_MULT3(a,b,c,t) (((a) * (b) * (c) + 32512) / 65025.0)
57
#define INT_BLEND(a,b,alpha,tmp) (INT_MULT((a) - (b), alpha, tmp) + (b))
61
48
/* A drawable has an alphachannel if contains either 4 or 2 bytes data
62
49
* aka GRAYA and RGBA and thus the macro below works. This will have
63
50
* to change if we support bigger formats. We'll do it so for now because