diff options
author | Marius Kintel <marius@kintel.net> | 2012-01-14 00:22:46 (GMT) |
---|---|---|
committer | Marius Kintel <marius@kintel.net> | 2012-01-14 00:22:46 (GMT) |
commit | 9267b15bd715cf9a2b709a4e87a8e9f3a395a0f5 (patch) | |
tree | 97991177c0dcf862f7f9c4cdfeb2ccb367732b1b /src/mainwin.cc | |
parent | 81f2d0a6104428a5fa59a47e6e5c8d662960579e (diff) |
Added experimental support for forcing OpenCSG to use the Goldfeather algorithm
Diffstat (limited to 'src/mainwin.cc')
-rw-r--r-- | src/mainwin.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mainwin.cc b/src/mainwin.cc index f8a6f43..a8507c0 100644 --- a/src/mainwin.cc +++ b/src/mainwin.cc @@ -41,6 +41,7 @@ #ifdef ENABLE_OPENCSG #include "CSGTermEvaluator.h" #include "OpenCSGRenderer.h" +#include <opencsg.h> #endif #include "ProgressWidget.h" #include "ThrownTogetherRenderer.h" @@ -347,6 +348,8 @@ MainWindow::MainWindow(const QString &filename) connect(Preferences::inst(), SIGNAL(requestRedraw()), this->glview, SLOT(updateGL())); connect(Preferences::inst(), SIGNAL(fontChanged(const QString&,uint)), this, SLOT(setFont(const QString&,uint))); + connect(Preferences::inst(), SIGNAL(openCSGSettingsChanged()), + this, SLOT(openCSGSettingsChanged())); Preferences::inst()->apply(); // make sure it looks nice.. @@ -1786,3 +1789,10 @@ void MainWindow::clearCurrentOutput() { set_output_handler(NULL, NULL); } + +void MainWindow::openCSGSettingsChanged() +{ +#ifdef ENABLE_OPENCSG + OpenCSG::setOption(OpenCSG::AlgorithmSetting, Preferences::inst()->getValue("advanced/forceGoldfeather").toBool() ? OpenCSG::Goldfeather : OpenCSG::Automatic); +#endif +} |