I've seen examples in silverlight where the achieve a effect using 1 of 2 ways:
- Two image objects, both displaying the same image, but the bottom one rotating it 180 degrees and applying a gradient image opacity
- A MediaElement object and a VideoBrush element.
I have a series of path objects, rectanges, etc which I would like to apply a reflection affect to. Is there a more elegant solution other than copying my objects manually and rotating them? Unfortunately the VideoBrush object only works on MediaElement objects, but is there something else I can use?
-
Not in Silverlight, in WPF you have a VisualBrush which can help with this but Silverlight doesn't have one in version 2. Just to be clear though, it's not a rotation it's a negative ScaleY on a ScaleTransform. The easiest thing is to put everything into a UserControl and then use two UserControls with one having a ScaleTransform and an OpacityMask on it.
-
For a good example, please see the following blog post from Mike Snow.
0 comments:
Post a Comment