ShadowFilter

This filter produces drop shadows for images. It uses the alpha channel of the image as the shape of the shadow. You can change the offset and direction of the shadow and its color, fuzziness and opacity. The output of this filter is an image is optionally larger than the input by the offsets and the shadow blur radius.

Below are the the original image, a shadow created with ShadowFilter and an inverse shadow made by inverting the alpha channel of the source image.

shadow shadow shadow
ShadowFilter