8

This same question was marked as a duplicate, so it never got answered here: Sketch: How to get a feathered mask?

This is not a duplicate. I'm asking about Sketch, not Photoshop.

7

You can get a feathering effect in some cases using alpha masking. However, this doesn't allow you to feather complex (or some simple) shapes in an easy way.

Alpha masking allows you to mask using an object filled with a gradient that includes transparency. The colours of the gradient are ignored and the transparent (or partially transparent) areas of the gradient become the transparent (or partially transparent) areas of the mask.

To use Alpha masking, select the object you've got set as a mask,
go to Layer > Mask Mode > Alpha Mask.
Then set up your gradient with partial transparency (alpha > 100%).

There's also a good video on the sketch app site: https://www.sketchapp.com/learn/documentation/shapes/masking/#alpha-masks

4

The original question was a good one, with a concrete example which is displayed on the sketch help page for Masking, and @Alex Magill's answer is helpful, (though the video is no longer available).

Here is a simple example:

doc example

...which can be achieved by:

  • insert your portrait
  • create a rectangle of the same size arranged below the portrait
  • select the rectangle and "Use as mask"
  • Layer > Mask > Mask Mode > Alpha Mask
  • change the mask's Fill mode to radial gradient, and change the right-hand gradient stop to 0% opacity.
  • tweak to taste: you'll probably need to re-centre the gradient fill, and you may need to add a third gradient stop to control the 'width' of the feathering, without changing the size of the entire gradient fill

However, it doesn't seem possible to feather masks in a way that isn't achieved with a simple gradient.

Because the question title is not limited to a circular mask (or the use of gradients), I'm going to outline the limitations of the current tools as I understand them.


I would like to create a feathered mask using a custom vector, which I had hoped could be achieved by:

  • create a custom vector shape
  • add a gaussian blur
  • arrange shape under the bitmap to be masked
  • "Use as mask"
  • Layer > Mask > Mask Mode > Alpha Mask

I see that when I "Use as Mask", the gaussian blur is deactivated, and reactivating it has no effect. I've considered whether the same effect could be achieved in another way, eg:

  • multiple shapes with gradient fills combined with Union
  • flatten the blurred shape, and use the resulting bitmap as a mask (undesirable)

...but no luck so far.

It seems that Fill is the only property which determines an alpha mask's effect.

I've submitted a feature request to allow any properties of a layer to contribute to an alpha mask's effect.

Here's a minimal reproducible example using Sketch 52.6.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.