diff -r 08dc62e03a6d -r c6114b3af3a6 src/gl/partrenderer.cpp --- a/src/gl/partrenderer.cpp Sun Feb 02 00:50:57 2020 +0200 +++ b/src/gl/partrenderer.cpp Sun Feb 02 00:51:06 2020 +0200 @@ -54,7 +54,6 @@ this->modelQuaternion = glm::angleAxis(glm::radians(30.0f), glm::vec3{-1, 0, 0}); this->modelQuaternion *= glm::angleAxis(glm::radians(225.0f), glm::vec3{-0, 1, 0}); this->updateViewMatrix(); - glLineWidth(2.0); this->update(); } @@ -110,6 +109,7 @@ glEnable(GL_DEPTH_TEST); glEnable(GL_POLYGON_OFFSET_FILL); glPolygonOffset(1.0f, 1.0f); + glLineWidth(this->renderPreferences.lineThickness); switch (this->renderPreferences.style) { case gl::RenderStyle::Normal: @@ -232,8 +232,9 @@ void PartRenderer::setRenderPreferences(const gl::RenderPreferences& newPreferences) { bool mainColorChanged = this->renderPreferences.mainColor != newPreferences.mainColor; + bool backgroundColorChanged = this->renderPreferences.backgroundColor != newPreferences.backgroundColor; this->renderPreferences = newPreferences; - if (mainColorChanged) + if (mainColorChanged or backgroundColorChanged) { this->compiler->build(this->model, this->documents, this->renderPreferences); }