Пример #1
0
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            _controller = new ImGuiController(Width, Height);

            //Set the current theme instance
            ColorTheme.UpdateTheme(new DarkTheme());

            //Disable the docking buttons
            ImGui.GetStyle().WindowMenuButtonPosition = ImGuiDir.None;

            //Enable docking support
            ImGui.GetIO().ConfigFlags |= ImGuiConfigFlags.DockingEnable;

            //Enable up/down key navigation
            ImGui.GetIO().ConfigFlags |= ImGuiConfigFlags.NavEnableKeyboard;
            //Only move via the title bar instead of the whole window
            ImGui.GetIO().ConfigWindowsMoveFromTitleBarOnly = true;

            //Init rendering data
            TimelineWindow.OnLoad();
            Pipeline.InitBuffers();

            camera_speed = Pipeline._camera.KeyMoveSpeed;

            InitDock();
            LoadRecentList();

            RenderTools.Init();

            ReloadGlobalShaders();

            var Thread2 = new Thread((ThreadStart)(() =>
            {
                //Init plugins
                Toolbox.Core.FileManager.GetFileFormats();
            }));

            Thread2.Start();

            ForceFocused = true;
        }