1#ifndef ALGORITHMCONTROLLER_H
2#define ALGORITHMCONTROLLER_H
5#include <QtConcurrent/QtConcurrent>
6#include <QFutureWatcher>
8#include <QElapsedTimer>
10#include "DataManager.h"
11#include "algorithmexecutor.h"
13#include "view/progressdialog.h"
14#include "view/samplingwidget.h"
16#include "plugin/algorithmmanager.h"
17#include "plugin/transformmanager.h"
20#define NO_TRANSFORM -1
25#define PROGRESS_DIALOG_DELAY_MS 500
103 void sig_algorithmFinished(
int index);
105 void sig_keyframesChangedByPlugin(QString name);
108 void slot_updateKeyframes(QString pluginName, std::vector<uint> keyframes);
109 void slot_updateBuffer(QString pluginName, QMap<QString, QVariant> buffer);
112 void slot_previewStateChanged(
bool enabled);
126 QFutureWatcher<std::vector<cv::Mat*>> m_fWatcher;
128 std::tuple<cv::Mat*,int, int> m_future;
129 std::tuple<cv::Mat*,int, int> m_fQueue;
130 void startNextTransform();
134 PluginType m_pluginType;
137 QElapsedTimer m_timer;
139 bool m_processRunning =
false;
140 bool m_progressDialogActivated =
false;
The AlgorithmController class is responsible for controlling the user input regarding algorithm selec...
Definition algorithmcontroller.h:40
void sig_hasStatusMessage(QString message)
[signal] sig_hasStatusMessage() is emitted when the status message is updated.
void slot_selectAlgorithm(int idx)
Slot which is called, when the selected Algorithm is changed to a IAlgorithm. The slot will show the ...
Definition algorithmcontroller.cpp:37
void slot_selectTransform(int idx)
Slot which is called, when the selected Algorithm is changed to a Transform algortihm....
Definition algorithmcontroller.cpp:55
void sig_stopPlay()
[signal] sig_stopPlay() is emitted when an algorithm is started to stop the VideoPlayer.
void slot_startGenerateSettings()
Slot which is called, when 'Generate settings' is clicked. The slot will start the algorithm by calli...
Definition algorithmcontroller.cpp:112
void slot_startAlgorithm()
Slot which is called, when 'Sample images' is clicked. The slot will start the algorithm by calling t...
Definition algorithmcontroller.cpp:70
void slot_showProgessDialog()
Slot which is called after a sampling process of settings generation process is started....
Definition algorithmcontroller.cpp:103
void slot_algorithmFinished(int idx)
Slot which is called, when the algorithm finished. This will close the ProgressDialog.
Definition algorithmcontroller.cpp:193
void slot_algorithmAborted()
Slot which is called, when the 'Abort' on the ProgressDialog is clicked. This will close the Progress...
Definition algorithmcontroller.cpp:147
The AlgorithmExecutor class is used to start the execution of a plugin(algorithm) and to provide sign...
Definition algorithmexecutor.h:36
The DataManager class is a Facade for the data holding classes in the model. It delegates most of it'...
Definition DataManager.h:29
The ProgressDialog class is the ui dialog holding the progress bar and abort/cancel button.
Definition progressdialog.h:22