Fix thumbnail rendering in CLI (#12129)

* Fix thumbnail rendering in CLI

* Remove OSMesa context flag

* Add stringified error message for glfwInit and glewInit

* micro refactor

---------

Co-authored-by: SoftFever <softfeverever@gmail.com>
This commit is contained in:
Ocraftyone
2026-02-10 00:08:22 -05:00
committed by GitHub
parent ed3f0e2898
commit abefb0e698
7 changed files with 36 additions and 32 deletions

View File

@@ -55,7 +55,10 @@ void Camera::select_next_type()
void Camera::auto_type(EType preferred_type)
{
if (!wxGetApp().app_config->get_bool("auto_perspective")) return;
if (wxApp::GetInstance() == nullptr || wxGetApp().app_config == nullptr)
return;
if (!wxGetApp().app_config->get_bool("auto_perspective"))
return;
if (preferred_type == EType::Perspective) {
if (!m_prevent_auto_type) {
set_type(preferred_type);
@@ -758,4 +761,3 @@ void Camera::update_target() {
}
} // GUI
} // Slic3r