svg对图片进行滤镜处理效果代码
代码语言:html
所属分类:其他
代码描述:svg对图片进行滤镜处理效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en" > <head> <meta charset="UTF-8"> <style> body { min-height: 100vh; display: flex; align-items: center; justify-content: center; margin: 0; padding: 0; } svg { height: 100vh; width: 100vw; } </style> </head> <body > <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" class="Playground__svg"> <defs> <filter id="filter" x="-20%" y="-20%" width="140%" height="140%" filterUnits="objectBoundingBox" primitiveUnits="userSpaceOnUse" color-interpolation-filters="linearRGB"> <feMorphology operator="dilate" radius="4 40" x="0%" y="0%" width="100%" height="100%" in="SourceGraphic" result="morphology1" /> <feColorMatrix type="luminanceToAlpha" x="0%" y="0%&q.........完整代码请登录后点击上方下载按钮下载查看
网友评论0