您好,欢迎访问一九零五行业门户网

使用 CSS 创建衰减阴影

阴影滤镜用于在指定的方向和颜色中创建一个衰减的阴影。
可以在此滤镜中使用以下参数 −
序号
参数和描述
1
颜色您想要的阴影颜色。
2
方向模糊的方向,顺时针方向,以45度为增量。默认值为270(左)。
0 = 顶部
45 = 右上
90 = 右侧
135 = 右下
180 = 底部
225 = 左下
270 = 左侧
315 = 左上
示例您可以尝试运行以下代码来实现阴影滤镜 −
演示
<html> <head> </head> <body> <img src="/css/images/logo.png" alt="css logo"style="filter: chroma(color = #000000) shadow(color=#00ff00, direction=225)"> <p>text example:</p> <div style="width: 357; height: 50; font-size: 30pt; font-family: arial black; color: red; filter: shadow(color=#0000ff, direction=225)">css tutorials</div> </body></html>
以上就是使用 css 创建衰减阴影的详细内容。
其它类似信息

推荐信息