BLENDING COLORS IN THE PRESENCE OF TRANSPARENCY
Methods and apparatus for blending colors in the presence of transparency. The method includes blending a lower and an upper graphic element in accordance with a transfer mode by calculating a transfer color from a lower element color and an upper element color according to the transfer mode without...
Gespeichert in:
1. Verfasser: | |
---|---|
Format: | Patent |
Sprache: | eng ; fre |
Schlagworte: | |
Online-Zugang: | Volltext bestellen |
Tags: |
Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
|
Zusammenfassung: | Methods and apparatus for blending colors in the presence of transparency. The method includes blending a lower and an upper graphic element in accordance with a transfer mode by calculating a transfer color from a lower element color and an upper element color according to the transfer mode without regard either to a lower element alpha or to an upper element alpha; calculating a resulting alpha from the lower element alpha and the upper element alpha without regard to any of the lower element color, the upper element color, or the transfer mode; and calculating a resulting color as a weighted average of the lower element color, the transfer color, and the upper element color. The transfer mode can be an arbitrary transfer mode and can be user defined. The resulting graphic element having color value C and alpha value c can be calculated in accordance with = XFade ( , XFade ( , , a ), b ), where XFade (, , z) - is an operation defined by the formulas r = InterpolateAlpha (x, y, z), t = y x z / r, and R = InterpolateColor (X, Y, t) and where the lower element is and the upper element is . Each of the colors A, B, and C can be defined by a value for each of a plurality of colorants. The calculated values can defined by c = a + b - axb, and C = Ax (1 - (b / c)) + Bx (1- a) x (b / c) + T (A, B) xax (b / c). |
---|