Verified Commit d9c56e60 authored by Tobias WEBER's avatar Tobias WEBER
Browse files

gl surface format bugfix

parent 1540d752
......@@ -491,6 +491,9 @@ MagStructFactDlg::MagStructFactDlg(QWidget* pParent) : QDialog{pParent},
auto ac3DView = new QAction("Unit Cell / Fourier Components...", menuFile);
auto ac3DViewSC = new QAction("Super Cell / Magnetic Moments...", menuFile);
// not yet implemented
acImportCIF->setEnabled(false);
menuFile->addAction(acNew);
menuFile->addSeparator();
menuFile->addAction(acLoad);
......@@ -533,6 +536,8 @@ MagStructFactDlg::MagStructFactDlg(QWidget* pParent) : QDialog{pParent},
m_dlgPlot->setWindowTitle("Unit Cell");
m_plot = std::make_shared<tl2::GlPlot>(this);
m_plot->setFormat(tl2::gl_format(1, _GL_MAJ_VER, _GL_MIN_VER, 8, m_plot->format()));
m_plot->GetRenderer()->SetLight(0, tl2::create<t_vec3_gl>({ 5, 5, 5 }));
m_plot->GetRenderer()->SetLight(1, tl2::create<t_vec3_gl>({ -5, -5, -5 }));
m_plot->GetRenderer()->SetCoordMax(1.);
......@@ -593,6 +598,8 @@ MagStructFactDlg::MagStructFactDlg(QWidget* pParent) : QDialog{pParent},
m_dlgPlotSC->setWindowTitle("Super Cell");
m_plotSC = std::make_shared<tl2::GlPlot>(this);
m_plotSC->setFormat(tl2::gl_format(1, _GL_MAJ_VER, _GL_MIN_VER, 8, m_plotSC->format()));
m_plotSC->GetRenderer()->SetLight(0, tl2::create<t_vec3_gl>({ 5, 5, 5 }));
m_plotSC->GetRenderer()->SetLight(1, tl2::create<t_vec3_gl>({ -5, -5, -5 }));
m_plotSC->GetRenderer()->SetCoordMax(1.);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment