
Originally Posted by
wossname
I like the MakeImageGreyscale() sub. Very neat.
MSDN seems to have very little to say on the subject of ColorMatrixes, do you have any links about it?
you mean creature, if you really liked it then you'd give me a rep point
all your rep points are belong to me!
umm to be honest I dont see why MSDN would provide anything on this. Color matrix relates more to mathematics, so ... 
HOWEVER, I wrote a lil nonsentual comment for one of my libraries, and I just copy paste it here. Looking at it, it's a bit vague because I was probably half sleep back then when I was writing it
but if you read it, I gave some examples so it should make sense what each thing in the color matrix means
PHP Code:
/*
* ColorMatrix Explanation:
* 1 0 0 0 0
* 0 1 0 0 0
* 0 0 1 0 0
* 0 0 0 1 0
* .37 .15 .07 0 1
*
* r = (r*1) + (g*0) + (b*0) + (a*0) + (1*.37) = r + .37
* g = (r*0) + (g*1) + (b*0) + (a*0) + (1*.15) = g + .15
* b = (r*0) + (g*0) + (b*1) + (a*0) + (1*.07) = b + .07
* a = (r*0) + (g*0) + (b*0) + (a*1) + (1*0) = a
*
* Max value for each r,g,b,a value is 1 which means 255. The 5th column is useless except for the last row (5,5).
* Last row is for translation
* Another explanation:
* RED rR gR bR aR 0
* GREEN rG gG bG aG 0
* BLUE rB gB bB aB 0
* ALPHA rA gA bA aA 0
* TRANSFORM fR fG fB fA F
*
* This will convert (R, G, B, A) to:
* R = (R*rR) + (G*gR) + (B*bR) + (A*aR) + (F*fR)
* G = (R*rG) + (G*gG) + (B*bG) + (A*aG) + (F*fG)
* B = (R*rB) + (G*gB) + (B*bB) + (A*aB) + (F*fB)
* A = (R*rA) + (G*gA) + (B*bA) + (A*aA) + (F*fB)
*/