WindowsCompositionSamples icon indicating copy to clipboard operation
WindowsCompositionSamples copied to clipboard

[Question] How to achieve this effect?

Open HppZ opened this issue 4 years ago • 6 comments

https://stackoverflow.com/questions/49718377/dropshadow-with-image-blur-uwp

HppZ avatar Aug 29 '19 06:08 HppZ

from Groove Music: image

HppZ avatar Aug 29 '19 06:08 HppZ

image

HppZ avatar Sep 06 '19 10:09 HppZ

I think you're looking for this control:

https://docs.microsoft.com/en-us/windows/communitytoolkit/controls/dropshadowpanel

assassin316 avatar Sep 25 '19 16:09 assassin316

this shadow is not solidcolorbrush, it is generated from that image.

image

HppZ avatar Sep 25 '19 23:09 HppZ

Hi @HppZ we'd recommend using Win2d to pre-blur the image, put that blurred surface in a visual, and parent that to the visual tree so that it's behind your image. Could you give that a try and see if you're able to get the effect you're looking for?

daneuber avatar Sep 30 '19 18:09 daneuber

I have implemented this effect in the ColorShadow control in CompositionProToolkit v1.0.1. Here are the details.

ratishphilip avatar May 30 '20 13:05 ratishphilip