1
$\begingroup$

I'm referring to this section: https://www.w3.org/TR/compositing-1/#simplealphacompositing

Considering the formula co = Cs x αs + Cb x αb x (1 - αs) the docs state then, that co is the

the premultiplied pixel value after compositing

I would argue that this is not the case, since in this article the resulting color is depicted with a capital C and in the case of premultiplied version, the lower case is used (c). I'm not really sure if this is the case, it's not too obvious from both docs and the article. So, is the result of co = Cs x αs + Cb x αb x (1 - αs) really a premultiplied value?

$\endgroup$
0
$\begingroup$

Yes, the statement in the W3C doc is correct. You can tell because the background term includes premultiplication by the background alpha αb. If it were non-premultiplied, it wouldn't have an αb in it.

$\endgroup$
  • $\begingroup$ Thanks! I'll accept your answer, I just have one more question. The terminology is weird here, With zero alpha meaning that the color does not contribute and partial alpha means that some percentage of the color contributes - it contributes? to what? How could this be written more naturally? Could we say "0 alpha meaning that the color does not contribute to the final pixel"? $\endgroup$ – uglycode Aug 7 '18 at 7:37
  • $\begingroup$ Yes, "does not contribute to the final color of the pixel" would be a good way to say it, or maybe "zero alpha meaning that the color has no influence on the final pixel color". $\endgroup$ – Nathan Reed Aug 7 '18 at 15:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.