im guessing grey is 50% transparent? then make it = (pixel in bitmap + pixel in background) / 2
im guessing grey is 50% transparent? then make it = (pixel in bitmap + pixel in background) / 2
it works thanks, I was looking for it, I didn't know that is so easy Big thanks my masterim guessing grey is 50% transparent? then make it = (pixel in bitmap + pixel in background) / 2
[I'm from Poland]
[Sorry for my English, because I just learn]
I thought that it works, but it works only for mask with RGB(128,128,128).
Example
Bitmap RGB(185,185,185)
Mask RGB(0,0,0)
Background RGB(100,0,0)
RED (185 + 100) * (0 / 256) = 285 * 0 = 0 // but should be 100
GREEN ...
BLUE ...
Bitmap RGB(185,185,185)
Mask RGB(100,100,100)
Background (100,0,0)
RED (185 + 0) * (100 / 256) = 185 / 0,390625 = 72 // but should be 133
GREEN ...
BLUE ...
So how do it correctly ?
[I'm from Poland]
[Sorry for my English, because I just learn]
hmm.. whats the point of a mask thats 0, 0, 0? that just means use all the data from the bitmap..
and for the second mask, well since 128, 128, 128 = 50% because 128 / 256 = .5..
100 / 256 = 0.390625, so use 0.390625 from the value of the pixel of bitmap and (1 - 0.390625 = 0.609375) from the value of the pixel of the background..
like so: 0.390625 * pixel in bitmap + 0.609375 * pixel in background
if you do the same for all other values of the mask, im sure you could figure out an algorithm so you can handle masks of all colors
yes yes it works at last thanks for help my master
[I'm from Poland]
[Sorry for my English, because I just learn]