How to animated grid background like instagram uwp app?

后端 未结 1 718
甜味超标
甜味超标 2021-01-06 14:22

The background keeps on transforming from one gradient to other very beautifully.I have no idea from where to start? Below are the screenshots:

1条回答
  •  栀梦
    栀梦 (楼主)
    2021-01-06 15:14

    Here's a simple example:

    XAML

    
    
        
            
                
                    
                    
                    
                    
                    
                    
                    
                
                
                    
                    
                    
                    
                    
                    
                    
                
            
        
    
        
            
                
                    
                    
                
            
    
            
                
                
                
                

    CS

    public sealed partial class MainPage : Page
    {
        public MainPage()
        {
            this.InitializeComponent();
            ((Storyboard)Resources["GradientAnimation"]).Begin();
        }
    }
    

    You probably don't want to use colors as saturated as I have in this example. Tweak them to your liking. Also adjust the SpeedRatio to your liking.

    0 讨论(0)
提交回复
热议问题