ΠΠΏΠΈΡΠ°Π½ΠΈΠ΅
The <blend-mode>
type is a collection of keywords describing blend modes.
A blend mode is a method of calculating the final color value of a pixel when layers overlap. Each blend mode takes the color value of the foreground and the backdrop (top color and bottom color respectively), perfoms its calculation and returns a color value. The final, visible layer is the result of performing the blend mode calculation on every overlapping pixel among the blended layers.
Π‘ΠΈΠ½ΡΠ°ΠΊΡΠΈΡ
Π€ΠΎΡΠΌΠ°Π»ΡΠ½ΡΠΉ ΡΠΈΠ½ΡΠ°ΠΊΡΠΈΡ: normal | multiply | screen | overlay | darken | lighten | color-dodge | color-burn | hard-light | soft-light | difference | exclusion | hue | saturation | color | luminosity
ΠΠΎΠ·ΠΌΠΎΠΆΠ½ΡΠ΅ Π·Π½Π°ΡΠ΅Π½ΠΈΡ
normal
-
The final color is the top color, whatever the bottom color may be.
The effect is similar to two opaque pieces of paper overlapping. multiply
-
The final color is the result of multiplying the top and bottom colors.
A black layer leads to a black final layer, and a white layer leads to no change.
The effect is similar to two images printed on transparent film overlapping. screen
-
The final color is the result of inverting the colors, multiplying them and inverting that color value.
A black layer leads to no change, and a white layer leads to a white final layer.
The effect is similar to two images shone onto a projection screen. overlay
- The final color is the result of
multiply
if the bottom color is darker, orscreen
if the bottom color is lighter.
This blend mode is equivalent tohard-light
but with the layers swapped. darken
-
The final color is a color composed of the darkest values per color channel.
lighten
-
The final color is a color composed of the lightest values per color channel.
color-dodge
-
The final color is the result of dividing the bottom color by the inverse of the top color.
A black foreground leads to no change. A foreground with the inverse color of the backdrop leads to a fully lit color.
This blend mode is similar to screen, but the foreground need only be as light as the inverse of the backdrop to reach a fully lit color. color-burn
-
This final color is the result of inverting the bottom color, dividing the value by the top color, and inverting that value.
A white foreground leads to no change. A foreground with the inverse color of the backdrop leads to a black final image.
This blend mode is similar to multiply, but the foreground need only be as dark as the inverse of the backdrop to make the final image black. hard-light
-
The final color is the result of
multiply
if the top color is darker, orscreen
if the top color is lighter.
This blend mode is equivalent tooverlay
but with the layers swapped.
The effect is similar to shining a harsh spotlight on the backdrop. soft-light
-
The final color is similar to hard-light, but softer.
This blend mode behaves similar tohard-light
.
The effect is similar to shining a diffused spotlight on the backdrop.
difference
-
The final color is the result of subtracting the darker of the two colors from the lighter one.
A black layer has no effect, while a white layer inverts the other layer's color. exclusion
-
The final color is similar to
difference,
but with less contrast.
As withdifference
, a black layer has no effect, while a white layer inverts the other layer's color. hue
-
The final color has the hue of the top color, while using the saturation and luminosity of the bottom color.
saturation
-
The final color has the saturation of the top color, while using the hue and luminosity of the bottom color.
A pure gray backdrop, having no saturation, will have no effect. color
-
The final color has the hue and saturation of the top color, while using the luminosity of the bottom color.
The effect preserves gray levels and can be used to colorize the foreground. luminosity
-
The final color has the luminosity of the top color, while using the hue and saturation of the bottom color.
This blend mode is equivalent to color, but with the layers swapped.
ΠΠ½ΡΠ΅ΡΠΏΠΎΠ»ΡΡΠΈΡ ΡΠ΅ΠΆΠΈΠΌΠΎΠ² Π½Π°Π»ΠΎΠΆΠ΅Π½ΠΈΡ
Changes between blends mode are not interpolated. Any change occurs abruptly.
Π‘ΠΏΠ΅ΡΠΈΡΠΈΠΊΠ°ΡΠΈΠΈ
Π‘ΠΏΠ΅ΡΠΈΡΠΈΠΊΠ°ΡΠΈΡ | Π‘ΡΠ°ΡΡΡ | ΠΠΎΠΌΠΌΠ΅Π½ΡΠ°ΡΠΈΠΉ |
---|---|---|
Compositing and Blending Level 1 ΠΠΏΡΠ΅Π΄Π΅Π»Π΅Π½ΠΈΠ΅ '<blend-mode>' Π² ΡΡΠΎΠΉ ΡΠΏΠ΅ΡΠΈΡΠΈΠΊΠ°ΡΠΈΠΈ. |
ΠΠ°Π½Π΄ΠΈΠ΄Π°Ρ Π² ΡΠ΅ΠΊΠΎΠΌΠ΅Π½Π΄Π°ΡΠΈΠΈ | ΠΠ΅ΡΠ²ΠΎΠ½Π°ΡΠ°Π»ΡΠ½ΠΎΠ΅ ΠΎΠΏΡΠ΅Π΄Π΅Π»Π΅Π½ΠΈΠ΅ |
Π‘ΠΎΠ²ΠΌΠ΅ΡΡΠΈΠΌΠΎΡΡΡ Ρ Π±ΡΠ°ΡΠ·Π΅ΡΠ°ΠΌΠΈ
ΠΡΠΎΠ±Π΅Π½Π½ΠΎΡΡΡ | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
---|---|---|---|---|---|
ΠΠ°Π·ΠΎΠ²Π°Ρ ΠΏΠΎΠ΄Π΄Π΅ΡΠΆΠΊΠ° | 35 | (ΠΠ°) | ? | ? | ? |
ΠΡΠΎΠ±Π΅Π½Π½ΠΎΡΡΡ | Android | Chrome for Android | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Safari Mobile |
---|---|---|---|---|---|---|
ΠΠ°Π·ΠΎΠ²Π°Ρ ΠΏΠΎΠ΄Π΄Π΅ΡΠΆΠΊΠ° | ? | ? | (ΠΠ°) | ? | ? | ? |
Π‘ΠΌΠΎΡΡΠΈΡΠ΅ ΡΠ°ΠΊΠΆΠ΅
- Properties using a value of this type:
background-blend-mode
andmix-blend-mode
- Blend modes
- CSS Reference index