Exemple #1
0
        public MainWindow()
        {
            string errorpath = System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) + "/ErrorLog/";

            Shared_Utility.Logger.Logger.Initialize(errorpath);

            InitializeComponent();
            Closing += (s, e) =>
            {
                Utility.IO.system.KillProcess("WPFEngine");
            };
            Loaded += delegate
            {
                DefaultScene.Parent = rbfxHost.Handle;

                Task.Run(() =>
                {
                    using (var context = new Context())
                    {
                        using (var application = new DefaultScene(context))
                        {
                            application.Context.Cache.AddResourceDir($"{App.LocaldllPath}/Resources/3D");
                            application.Run();
                        }
                    }
                });
            };
        }
Exemple #2
0
 static void Main(string[] args)
 {
     using (var context = new Context())
     {
         using (var application = new DefaultScene(context))
         {
             application.Run();
         }
     }
 }