I am using user input images as the Frame Background in my app and I want to darken the image. Reducing opacity does the opposite and brightens the image as the Window color is white on Desktop and not black and I can't see any function to change the color of window.
- Changing TitleBar Color doesn't work.
- Changing the RequestedTheme from Light to Dark doesn't change the color.
- Processing the image to darken is too slow and can't be used.
Here's the code to change the Frame background where 'image' is my BitmapImage object.
ImageBrush b = new ImageBrush();
b.ImageSource = image;
b.Stretch = Stretch.UniformToFill;
(Window.Current.Content as Frame).Background = b;
I need to use the Background on Frame and not on Page as navigation to other pages needs to be smooth and keep the background in place.