using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Windows; using System.Windows.Controls; using System.Windows.Data; using System.Windows.Documents; using System.Windows.Input; using System.Windows.Media; using System.Windows.Media.Imaging; using System.Windows.Navigation; using System.Windows.Shapes; using System.Threading; using System.Windows.Threading; using DownBox2; namespace Snow1 { /// <summary> /// MainWindow.xaml 的交互逻辑 /// </summary> public partial class MainWindow : Window { private const Double Speed = 0.1; Image i = new Image(); private List<Image> Snowflake; private List<Image> ReSnowflake; private Boolean[] IsBottom; private const int SnowflakeLen = 48, ReSnowflakeLen = 24; private const int SnowflakeWidth = 10; private Random random; private List<int> SnowflakeY; private ThreadStart ts; private Thread td; private DownBox db; public MainWindow() { InitializeComponent(); random = new Random(); Init(@"Image/x3.png",@"Image/x4.png"); ts = new ThreadStart(ThreadFun); td = new Thread(ts); RenderOptions.SetBitmapScalingMode(i, BitmapS