r/Affinity • • 16d ago

Designer Export shaped-feathered gradient to SVG

I'm currently working on this graphic where I want to use a blurry outline of the magnifying glass as clipping mask and export it to SVG. Currently it's generated via the gaussiann blur effect, which is pixelbased, so when I export it to SVG it is either rasterized or the blur is gone.

I'm searching for an altenative approach that could be saved as a vector graphic. I know that it would be possible to use mesh gradient and draw the shape by hand and adjust the gradients accordingly (like the on the outer feathered edge). But I want to know if you can think of a more simple/ elegant solution to this problem.

2 Upvotes

5 comments sorted by

1

u/Few_Mention8426 16d ago

mesh gradients woudnt work either as its not supported in svg 1.1 or 2

you could copy the magnifying glass, split it into the larger circle, the stem, the handle and then another smaller circle at the bottom of the handle,

Then make a large stroke around each, expand the stroke into a path, then use a combination or radial and linear gradients with white at one end and transparent at the other....

use that as a transparency/opacity mask

(it may have to be black not transparent but i havent got affinity in front of me to experiment)

1

u/Knuftedufte 16d ago

Well mesh gradients are at least exported looking right, but looking into the SVG code, you're right also rasterized as an image

What exactly do you mean with opacitiy mask?

1

u/Few_Mention8426 16d ago

if you just make a vector shape with a liniar or radia gradient, and then use it as a mask, it should export as svg fine,

(I said opacity mask when i just meant mask.)

1

u/Knuftedufte 14d ago

Ah okay, so the basic idea you're proposing is: combining multiple simpler gradients together into mask?

1

u/Few_Mention8426 14d ago

correct yes