-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathmainwindow.h
100 lines (71 loc) · 2.14 KB
/
mainwindow.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include <QGraphicsScene>
#include <QMainWindow>
#include <QTimer>
#include <QVector>
#include <QtCharts/QLineSeries>
#include <QtCharts/QtCharts>
#include "CaptureShowTask/CaptureShowTask.h"
#include "CaptureTask/CaptureTask.h"
#include "Utility/AnsysSetting/ansyssetting.h"
#include "settingconfig.h"
QT_BEGIN_NAMESPACE
namespace Ui {
class MainWindow;
}
QT_END_NAMESPACE
class MainWindow : public QMainWindow {
Q_OBJECT
public:
explicit MainWindow(QWidget *parent = nullptr);
~MainWindow() override;
void set_video_show(QSize size, bool is_signal = false);
QObject *get_member(QString);
auto *get_captureShowTask() { return m_captureShowTask; }
private:
static std::vector<int> RefreshCameraNum(QSize *size);
void RefreshCaptureSelect();
void Ui_Init(QSize size);
void initializeMemberMap();
public slots:
void on_pushButtonOpen_clicked();
void on_pushButtonClose_clicked();
void on_actionImportVideos_triggered();
void on_actionFPS_triggered();
void on_actionSetting_triggered();
signals:
void mainWindowCreated(MainWindow *);
void thisCapture(int number);
void switchCapture(bool);
void SendVideoFileName(QString);
void SendFpsNumber(int);
void alg_selected(QString);
void send_rect(cv::Rect *);
void ShowFFT();
void is_open(bool);
public:
Ui::MainWindow *ui;
private:
bool m_captureOpenFlag = false;
bool m_chart_windows_status = false;
QString m_videoFileName;
bool m_videoFileFlag = false;
int m_fpsConfig = 1;
std::vector<int> m_captureNumber;
int m_selectedCapture = 0;
AnsysSetting *ansys_setting;
QThread *threadVideoShowTask;
QThread *threadVideoTask;
CaptureShowTask *m_captureShowTask;
CaptureTask *m_captureTask;
SettingConfig *m_settingDialog;
QSize m_init_size;
cv::Rect *m_wait_send_rect = nullptr;
QMap<QString, QObject *> memberMap;
QList<QThread *> axesThreadList;
int axesThreadListLength = 6;
int axesThreadListCount = 0;
QVector<QPair<QChartView *, AxesFreshTask *>> axesTaskList;
};
#endif // MAINWINDOW_H