SVG (Scalable Vector Graphics)의 filter μš”μ†ŒλŠ” κ·Έλž˜ν”½ μš”μ†Œμ— 그림자 효과, λΈ”λŸ¬, 색상 μ‘°μ • λ“± λ‹€μ–‘ν•œ μ‹œκ°μ  효과λ₯Ό μ μš©ν•˜λŠ” 데 μ‚¬μš©λ©λ‹ˆλ‹€. λ‹€μŒμ€ λͺ‡ κ°€μ§€ filter의 μ˜ˆμ‹œμž…λ‹ˆλ‹€.

  1. 그림자 효과 (Drop Shadow):

    xml
    <svg width="200" height="200" xmlns="http://www.w3.org/2000/svg"> <defs> <filter id="drop-shadow" x="-20%" y="-20%" width="140%" height="140%"> <feOffset result="offOut" in="SourceAlpha" dx="5" dy="5" /> <feGaussianBlur result="blurOut" in="offOut" stdDeviation="3" /> <feBlend in="SourceGraphic" in2="blurOut" mode="normal" /> </filter> </defs> <rect width="100" height="100" rx="10" ry="10" fill="#3498db" filter="url(#drop-shadow)" /> </svg>
  2. λΈ”λŸ¬ 효과:

    xml
    <svg width="200" height="200" xmlns="http://www.w3.org/2000/svg"> <defs> <filter id="blur" x="0" y="0" width="100%" height="100%"> <feGaussianBlur in="SourceGraphic" stdDeviation="5" /> </filter> </defs> <rect width="100" height="100" rx="10" ry="10" fill="#e74c3c" filter="url(#blur)" /> </svg>
  3. 색상 ν–‰λ ¬ μ‘°μ •:

    xml
    <svg width="200" height="200" xmlns="http://www.w3.org/2000/svg"> <defs> <filter id="hue-rotate" color-interpolation-filters="sRGB"> <feColorMatrix type="hueRotate" values="90" /> </filter> </defs> <rect width="100" height="100" rx="10" ry="10" fill="#27ae60" filter="url(#hue-rotate)" /> </svg>
  4. 밝기 쑰절:

    xml
    <svg width="200" height="200" xmlns="http://www.w3.org/2000/svg"> <defs> <filter id="brightness" color-interpolation-filters="sRGB"> <feComponentTransfer> <feFuncR type="linear" slope="1.5" /> <feFuncG type="linear" slope="1.5" /> <feFuncB type="linear" slope="1.5" /> </feComponentTransfer> </filter> </defs> <rect width="100" height="100" rx="10" ry="10" fill="#f39c12" filter="url(#brightness)" /> </svg>

이 μ˜ˆμ‹œλ“€μ€ filter μš”μ†Œλ₯Ό μ‚¬μš©ν•˜μ—¬ λ‹€μ–‘ν•œ μ‹œκ°μ  효과λ₯Ό μ μš©ν•˜λŠ” 방법을 λ³΄μ—¬μ€λ‹ˆλ‹€. filterλŠ” λ‹€μ–‘ν•œ 효과 및 필터링을 μ§€μ›ν•˜λ―€λ‘œ ν•„μš”μ— 따라 μ μ ˆν•œ 효과λ₯Ό 찾을 수 μžˆμŠ΅λ‹ˆλ‹€.