css 實現高斯模糊


<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<style>
	*{
		margin: 0;
		padding: 0;
		list-style: none;
	}
	.box{
		width: 100%;
		height: 300px;
		
	}
	.box img{width: 100%}
	.blur {	
	    filter: url(blur.svg#blur); /* FireFox, Chrome, Opera */
	    -webkit-filter: blur(40px); /* Chrome, Opera */
	       -moz-filter: blur(40px);
	        -ms-filter: blur(40px);    
	            filter: blur(40px);	
	    filter: progid:DXImageTransform.Microsoft.Blur(PixelRadius=10, MakeShadow=false); /* IE6~IE9 */
	}
</style>		
<body>
	<div class="box">
		<img src="1.jpg" alt="">
		<img src="1.jpg" alt="" class="	blur">
	</div>
</body>
</html>

  


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM