use OutputDevice to set fileinfo,
use new connect function,
This commit is contained in:
@@ -37,16 +37,11 @@ private:
|
||||
|
||||
public:
|
||||
void drawGeometry(QOpenGLShaderProgram *program, bool wireframe);
|
||||
|
||||
// slots
|
||||
public slots:
|
||||
void loadFile(QString filePath);
|
||||
|
||||
|
||||
// signals
|
||||
signals:
|
||||
void requestResetView();
|
||||
void requestUpdate();
|
||||
void sendFileInfo(QString name, QVector<Material>* materials, int vertices, int triangle);
|
||||
};
|
||||
|
||||
|
@@ -58,7 +58,6 @@ private:
|
||||
// functions
|
||||
private:
|
||||
void initShaders();
|
||||
void setConnections();
|
||||
void resetView();
|
||||
void updateLightPosition();
|
||||
|
||||
@@ -89,8 +88,5 @@ public slots:
|
||||
void setAttFac(double value);
|
||||
void setAmbCoef(double value);
|
||||
|
||||
// signals
|
||||
signals:
|
||||
void loadFile(QString);
|
||||
};
|
||||
|
||||
|
@@ -1,6 +1,8 @@
|
||||
#pragma once
|
||||
#include <QObject>
|
||||
|
||||
struct Material;
|
||||
|
||||
class OutputDevice : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
@@ -20,8 +22,11 @@ public:
|
||||
};
|
||||
|
||||
void print(QString message, int severity) { emit sendMessage(message, severity); };
|
||||
void setFileInfo(QString name, QVector<Material>* materials, int vertices, int triangle) {
|
||||
emit sendFileInfo(name, materials, vertices, triangle);
|
||||
};
|
||||
|
||||
signals:
|
||||
void sendMessage(QString message, int severity);
|
||||
|
||||
void sendFileInfo(QString name, QVector<Material>* materials, int vertices, int triangle);
|
||||
};
|
Reference in New Issue
Block a user