Efficients Drop shadows for non opaque components


#1

hi,

I have a question about how to efficiently display a drop shadow around a non opaque component efficiently (typically an opaque rectangle with rounded corners).

For now there’s only DropShadower which is efficient but only works for opaque components or DropShadowEffect which is accurate but each repaint (like a vu meter) inside the components forces a new drop shadow computation.
What would be the the best way to do that?


#2

I just fill a path at a very translucent shade of black, Colour::fromRGBA(0,0,0,8), over and over again at different offsets, then draw the main object.


Thoughts on sliders