SWBF2-Classic-Msh-Viewer/QtMeshViewer/Source/MainWindow.cpp

26 lines
527 B
C++

#include "..\Header\MainWindow.h"
#include "..\Header\OglViewerWidget.h"
#include <QSurfaceFormat>
MainWindow::MainWindow(QWidget *parent)
: QMainWindow(parent)
, ui(new Ui::MainWindowClass)
{
ui->setupUi(this);
QSurfaceFormat format;
format.setDepthBufferSize(24);
QSurfaceFormat::setDefaultFormat(format);
setCentralWidget(new OglViewerWidget(this));
setWindowIcon(QIcon(":/images/icon.ico"));
setWindowTitle("Mesh Viewer");
ui->statusBar->showMessage("pre-alpha");
}
MainWindow::~MainWindow()
{
delete ui;
}