public int blend(int color1,int color2, int factor)
{
int f1=256-factor;
return ( ( ( (c1&0xFF00FF)*f1 + (c2&0xFF00FF)*factor ) &0xFF00FF00 ) | ( ( (c1&0x00FF00)*f1 + (c2&0x00FF00)*factor ) &0x00FF0000 ) ) >>>8;
}
public int blend(int color1,int color2, int factor)
{
int f1=256-factor;
return ( ( ( (c1&0xFF00FF)*f1 + (c2&0xFF00FF)*factor ) &0xFF00FF00 ) | ( ( (c1&0x00FF00)*f1 + (c2&0x00FF00)*factor ) &0x00FF0000 ) ) >>>8;
}