时间:2021-07-01 10:21:17 帮助过:19人阅读
<!DOCTYPE html> <html > <head> <meta charset="UTF-8"> <title>利用canvas 画布制作逼真的水滴特效</title> <meta name="keywords" content="利用canvas 画布制作逼真的水滴特效" /> <meta name="description" content="利用canvas 画布制作逼真的水滴特效" /> <style> /* NOTE: The styles were added inline because Prefixfree needs access to your styles and they must be inlined if they are on local disk! */ body { background-color: black; } canvas { position: absolute; top: 0; left: 0; -webkit-filter: blur( 10px ) contrast( 10 ); -moz-filter: blur( 10px ) contrast( 10 ); filter: blur( 10px ) contrast( 10 ); } </style> </head> <body> <canvas id=c></canvas> <script src="js/index.js"></script> </body> </html> Css部分: body { background-color: black; } canvas { position: absolute; top: 0; left: 0; -webkit-filter: blur( 10px ) contrast( 10 ); -moz-filter: blur( 10px ) contrast( 10 ); filter: blur( 10px ) contrast( 10 ); }
相信看了这些案例你已经掌握了方法,更多精彩请关注Gxl网其它相关文章!
相关阅读:
用H5制作烟花粒子特效的制作方法
html与xhtml的区别详解
网页的效果图与DIV+CSS关系
以上就是用H5制作水滴特效教程的详细内容,更多请关注Gxl网其它相关文章!