merge upstream changes

Signed-off-by: SoftFever <103989404+SoftFever@users.noreply.github.com>
This commit is contained in:
SoftFever 2023-01-21 00:37:10 +08:00
parent 1bdedb1c47
commit 2492e5d39c
156 changed files with 33597 additions and 65667 deletions

View file

@ -78,7 +78,9 @@ using namespace nlohmann;
#include "slic3r/GUI/Camera.hpp"
#include <GLFW/glfw3.h>
#ifdef __WXGTK__
#include <X11/Xlib.h>
#endif
#ifdef SLIC3R_GUI
#include "slic3r/GUI/GUI_Init.hpp"
@ -332,6 +334,10 @@ int CLI::run(int argc, char **argv)
// startup if gtk3 is used. This env var has to be set explicitly to
// instruct the window manager to fall back to X server mode.
::setenv("GDK_BACKEND", "x11", /* replace */ true);
// Also on Linux, we need to tell Xlib that we will be using threads,
// lest we crash when we fire up GStreamer.
XInitThreads();
#endif
// Switch boost::filesystem to utf8.