Board Logo

Color Picker
huytri - 7/28/2005 at 07:56 AM

I'm using the Tigra Color Picker with algorithm following
for (j = 0; j < 12; j ++) {
for (k = 0; k < 3; k ++){
for (i = 0; i <= 5; i ++){
R=k * 51 + (j % 2) * 51 * 3;
G=Math.floor(j / 2) * 51;
B=i * 51;
}
}
}
Now, I have a color as "FF0000", I want convert from R of rgb to K.
Who know to help me.
Thanks.


Softcomplex: http://www.softcomplex.com/
Back to forum: http://www.softcomplex.com/forum/