Additive color mixing with svg-filter

Additive color mixing with svg-filter

by denvdmj

HTML

<h1>Additive color mixing with svg-filter</h1>
<svg width="300" height="300">
  <defs>
    <filter id="additive">
      <feFlood x="50" y="50" width="200" height="200" flood-color="#0F0" result="a"/>
      <feFlood x="100" y="100" width="200" height="200" flood-color="#F00" result="b"/>
      <feBlend in="a" in2="b" result="ab" mode="screen"/>
     </filter>
  </defs>
  <rect filter="url(#additive)" width="100%" height="100%"/>
</svg>