图像模糊与CSS/Javascript:是可能吗?

前端之家收集整理的这篇文章主要介绍了图像模糊与CSS/Javascript:是可能吗?前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
是否可以使用CSS和Javascript添加模糊效果到图像?

解决方法

是的, this works a treat

Pixastic is an experimental library which allows you to perform a variety of operations on images using just a bit of JavaScript. The effects supported out of the Box include desaturation/greyscale,invert,flipping,brightness/contrast adjustment,hue/saturation,emboss,blur,and many more…

Pixastic works by utilizing the HTML5 Canvas element which provides access to raw pixel data,thereby opening up for more advanced image effects. This is where the “experimental” part comes into play. Canvas is only supported by some browsers and unfortunately Internet Explorer is not one of them. It is however well supported in both Firefox and Opera and support for Safari only just arrived with the recent Safari 4 (beta) release. Chrome currently works in the dev channel. A few of the effects have been simulated in IE using the age old proprietary filters. While these filters are much faster than their Canvas friends,they are few and limited. Hopefully we will one day have real Canvas on IE as well…

猜你在找的CSS相关文章