Beispiel #1
0
        protected override SC_message_object_jitter[][] init_update_variables(SC_message_object_jitter[][] _sc_jitter_tasks, sccsVD4VE_LightNWithoutVr.sc_core.sc_system_configuration configuration, IntPtr hwnd, sc_console.sc_console_writer _writer)
        {
            try
            {
                startTime = DateTime.Now;


                HWND = hwnd;

                _configuration = configuration;

                _currentWriter = _writer;


                //ReadKeyboard();
                //Camera = new DCamera();

                //swtch_for_last_pos = new int[MainWindow._physics_engine_instance_x * MainWindow._physics_engine_instance_y * MainWindow._physics_engine_instance_z][];

                //RAYCAST STUFF
                //_some_reset_for_applying_force = new int[MainWindow._physics_engine_instance_x * MainWindow._physics_engine_instance_y * MainWindow._physics_engine_instance_z][];
                //_some_last_frame_vector = new JVector[MainWindow._physics_engine_instance_x * MainWindow._physics_engine_instance_y * MainWindow._physics_engine_instance_z][][];
                //_some_last_frame_rigibodies = new RigidBody[MainWindow._physics_engine_instance_x * MainWindow._physics_engine_instance_y * MainWindow._physics_engine_instance_z][][];



                Thread main_thread_update = new Thread(() =>
                {
                    _thread_looper:

                    try
                    {
                        DoWork(0);
                    }
                    catch (Exception ex)
                    {
                    }
                    Thread.Sleep(1);
                    goto _thread_looper;

                    //ShutDown();
                    //ShutDownGraphics();
                }, 0);

                main_thread_update.IsBackground = true;
                main_thread_update.SetApartmentState(ApartmentState.STA);
                main_thread_update.Start();

                Camera = new _sc_camera();

                _shaderManager = new SC_ShaderManager();
                _shaderManager.Initialize(D3D.Device, HWND);

                _desktopDupe = new SC_SharpDX_ScreenCapture(0, 0, D3D.device);

                _graphics_sec    = new sc_graphics_sec();
                _sc_jitter_tasks = _graphics_sec._sc_create_world_objects(_sc_jitter_tasks);
            }
            catch
            {
            }
            return(_sc_jitter_tasks);
        }
Beispiel #2
0
 protected abstract SC_message_object_jitter[][] init_update_variables(SC_message_object_jitter[][] _sc_jitter_tasks, sccsVD4VE_LightNWithoutVr.sc_core.sc_system_configuration configuration, IntPtr hwnd, sc_console.sc_console_writer _writer); //void Update();