Paint Splatter Photo Mask
A photo revealed through organic paint splatters, with an amount slider and a re-roll button.
AI prompt
Mixed media poster of a vibrant sunset landscape photograph revealed only through an irregular black-ink-like paint splatter shape on warm off-white paper, the splatter edges organic with fine droplets and a couple of long drips running downward, a faint coral watercolour splash behind it, a few tiny ink dots scattered around the edges, tactile paper grain. Negative: straight edges, digital borders, text, clutter. Reduced motion: still image.About this pattern
Definition
Mixed-media layouts often show a photo only where paint has landed, as if it were splashed onto paper. In SVG this is a mask: white splatter shapes reveal the picture, black hides it. A gooey blur-and-threshold filter merges nearby circles into organic blobs with drips.
When to use it
- Build the mask from random circles of different sizes, a few large and many small.
- Blur the mask shapes and then raise the alpha contrast with feColorMatrix so edges become crisp but organic.
- Add a few elongated drips for the paint feel.
- Put a light paper texture and a faint coloured splash behind the photo.
What the controls do
- Amount slider and a New splatter button.
Motion & timing
- Splatters redraw instantly when changed.
- Reduced motion: no animation is involved.
Tips & variations
- Decorative masks should not hide important content in the photo.
- Provide the photo with an alt text on the real page.
Code of this live preview
<div class="bx"><svg class="dw" id="dw" viewBox="0 0 300 140" role="img" aria-label="A sunset photo revealed through paint splatter shapes"><defs><filter id="goo" x="-10%" y="-10%" width="120%" height="120%"><feGaussianBlur stdDeviation="4"/><feColorMatrix values="1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 22 -9"/></filter><mask id="mk"><rect width="300" height="140" fill="#000"/><g id="sp" filter="url(#goo)" fill="#fff"></g></mask><linearGradient id="sk" x1="0" y1="0" x2="0" y2="1"><stop offset="0" stop-color="#2a3a7a"/><stop offset=".5" stop-color="#e5683d"/><stop offset=".7" stop-color="#ffc561"/></linearGradient></defs><rect width="300" height="140" fill="#f7f1e6"/><circle cx="90" cy="40" r="40" fill="#f6a9a0" opacity=".35"/><g mask="url(#mk)"><rect width="300" height="140" fill="url(#sk)"/><circle cx="150" cy="86" r="22" fill="#fff0b8"/><path d="M0 100 Q60 70 120 98 T240 92 T300 100 V140 H0Z" fill="#1d2a4d"/><path d="M0 118 Q80 100 160 120 T300 112 V140 H0Z" fill="#101a33"/></g></svg><label class="rw">Amount <b id="av">14</b><input id="as" type="range" min="4" max="30" value="14"></label><button class="mini" id="nw" type="button">New splatter</button></div>:root{--bg:#F1F1EF;--surface:#fff;--surface-2:#F7F7F5;--line:#E0E0DC;--text:#171717;--muted:#6f6f6f;--accent:#171717;--accent-ink:#fff;--danger:#d92d20}
*{box-sizing:border-box;margin:0}
button{font:inherit;color:inherit;background:none;border:0;padding:0;cursor:pointer}a{color:inherit;text-decoration:none}ul,ol,p,h4{margin:0;padding:0}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.pre{display:flex;gap:5px;flex-wrap:wrap}.pre button{height:28px;padding:0 11px;border-radius:99px;border:1px solid var(--line);background:var(--surface);font-size:11px;cursor:pointer}
.pre button[aria-pressed=true]{background:var(--accent);color:var(--accent-ink);border-color:var(--accent)}
.bx{width:min(330px,100%);display:grid;gap:9px}.rw{display:grid;gap:3px;font-size:11.5px;color:var(--muted)}.rw b{color:var(--text);font-weight:600}input[type=range]{width:100%;accent-color:#171717}
.out{font-size:12px;color:var(--muted);line-height:1.4}.out b{color:var(--text)}
button:focus-visible,input:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.dw{width:100%;height:auto;border:1px solid var(--line);border-radius:12px;display:block}.mini{height:30px;padding:0 14px;border-radius:99px;border:1px solid var(--line);background:var(--surface);font-size:12px;font-weight:600;cursor:pointer}.mini:disabled{opacity:.4;cursor:default}
@media (prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}const sp=document.getElementById('sp'),as=document.getElementById('as');let seed=3;
function up(){let s=seed;const R=()=>(s=(s*1664525+1013904223)%4294967296)/4294967296,n=+as.value;let h='<ellipse cx="150" cy="70" rx="'+(30+n*2)+'" ry="'+(22+n*1.3)+'"/>';for(let i=0;i<n;i++){const a=R()*6.283,d=22+R()*95,x=150+Math.cos(a)*d*1.5,y=70+Math.sin(a)*d*.62,r=3+R()*(i<n/3?15:7);h+='<circle cx="'+x.toFixed(1)+'" cy="'+y.toFixed(1)+'" r="'+r.toFixed(1)+'"/>';}
for(let i=0;i<3;i++){const x=70+R()*160,y=70+R()*30,l=18+R()*34;h+='<rect x="'+x.toFixed(1)+'" y="'+y.toFixed(1)+'" width="3.5" height="'+l.toFixed(1)+'" rx="1.7"/><circle cx="'+(x+1.7).toFixed(1)+'" cy="'+(y+l+2).toFixed(1)+'" r="3"/>';}
sp.innerHTML=h;document.getElementById('av').textContent=n;}
as.addEventListener('input',up);document.getElementById('nw').addEventListener('click',()=>{seed=(seed*7+13)%9973;up();});up();One complete HTML file. Save it and open it in a browser.
<!doctype html>
<html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><title>Paint Splatter Photo Mask — demo</title>
<style>
:root{--bg:#F1F1EF;--surface:#fff;--surface-2:#F7F7F5;--line:#E0E0DC;--text:#171717;--muted:#6f6f6f;--accent:#171717;--accent-ink:#fff;--danger:#d92d20}
*{box-sizing:border-box;margin:0}
html,body{height:100%}body{background:var(--bg);color:var(--text);font:15px/1.5 -apple-system,BlinkMacSystemFont,'Segoe UI',Inter,Roboto,sans-serif;-webkit-font-smoothing:antialiased}.stage{min-height:100%;display:grid;place-items:center;padding:24px}button,input,select,textarea{font-family:inherit}@media (prefers-reduced-motion:reduce){html{scroll-behavior:auto}}
button{font:inherit;color:inherit;background:none;border:0;padding:0;cursor:pointer}a{color:inherit;text-decoration:none}ul,ol,p,h4{margin:0;padding:0}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.pre{display:flex;gap:5px;flex-wrap:wrap}.pre button{height:28px;padding:0 11px;border-radius:99px;border:1px solid var(--line);background:var(--surface);font-size:11px;cursor:pointer}
.pre button[aria-pressed=true]{background:var(--accent);color:var(--accent-ink);border-color:var(--accent)}
.bx{width:min(330px,100%);display:grid;gap:9px}.rw{display:grid;gap:3px;font-size:11.5px;color:var(--muted)}.rw b{color:var(--text);font-weight:600}input[type=range]{width:100%;accent-color:#171717}
.out{font-size:12px;color:var(--muted);line-height:1.4}.out b{color:var(--text)}
button:focus-visible,input:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.dw{width:100%;height:auto;border:1px solid var(--line);border-radius:12px;display:block}.mini{height:30px;padding:0 14px;border-radius:99px;border:1px solid var(--line);background:var(--surface);font-size:12px;font-weight:600;cursor:pointer}.mini:disabled{opacity:.4;cursor:default}
@media (prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}
</style></head>
<body><div class="stage">
<div class="bx"><svg class="dw" id="dw" viewBox="0 0 300 140" role="img" aria-label="A sunset photo revealed through paint splatter shapes"><defs><filter id="goo" x="-10%" y="-10%" width="120%" height="120%"><feGaussianBlur stdDeviation="4"/><feColorMatrix values="1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 22 -9"/></filter><mask id="mk"><rect width="300" height="140" fill="#000"/><g id="sp" filter="url(#goo)" fill="#fff"></g></mask><linearGradient id="sk" x1="0" y1="0" x2="0" y2="1"><stop offset="0" stop-color="#2a3a7a"/><stop offset=".5" stop-color="#e5683d"/><stop offset=".7" stop-color="#ffc561"/></linearGradient></defs><rect width="300" height="140" fill="#f7f1e6"/><circle cx="90" cy="40" r="40" fill="#f6a9a0" opacity=".35"/><g mask="url(#mk)"><rect width="300" height="140" fill="url(#sk)"/><circle cx="150" cy="86" r="22" fill="#fff0b8"/><path d="M0 100 Q60 70 120 98 T240 92 T300 100 V140 H0Z" fill="#1d2a4d"/><path d="M0 118 Q80 100 160 120 T300 112 V140 H0Z" fill="#101a33"/></g></svg><label class="rw">Amount <b id="av">14</b><input id="as" type="range" min="4" max="30" value="14"></label><button class="mini" id="nw" type="button">New splatter</button></div>
</div>
<script>
const sp=document.getElementById('sp'),as=document.getElementById('as');let seed=3;
function up(){let s=seed;const R=()=>(s=(s*1664525+1013904223)%4294967296)/4294967296,n=+as.value;let h='<ellipse cx="150" cy="70" rx="'+(30+n*2)+'" ry="'+(22+n*1.3)+'"/>';for(let i=0;i<n;i++){const a=R()*6.283,d=22+R()*95,x=150+Math.cos(a)*d*1.5,y=70+Math.sin(a)*d*.62,r=3+R()*(i<n/3?15:7);h+='<circle cx="'+x.toFixed(1)+'" cy="'+y.toFixed(1)+'" r="'+r.toFixed(1)+'"/>';}
for(let i=0;i<3;i++){const x=70+R()*160,y=70+R()*30,l=18+R()*34;h+='<rect x="'+x.toFixed(1)+'" y="'+y.toFixed(1)+'" width="3.5" height="'+l.toFixed(1)+'" rx="1.7"/><circle cx="'+(x+1.7).toFixed(1)+'" cy="'+(y+l+2).toFixed(1)+'" r="3"/>';}
sp.innerHTML=h;document.getElementById('av').textContent=n;}
as.addEventListener('input',up);document.getElementById('nw').addEventListener('click',()=>{seed=(seed*7+13)%9973;up();});up();
</script>
</body></html>