-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathZmqTrackingAlgorithm.h
More file actions
80 lines (55 loc) · 1.67 KB
/
ZmqTrackingAlgorithm.h
File metadata and controls
80 lines (55 loc) · 1.67 KB
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
#pragma once
#include <vector>
#include <memory>
#include <set>
#include <boost/optional.hpp>
#include <boost/filesystem/operations.hpp>
#include <opencv2/opencv.hpp>
#include <QFile>
#include <QWidget>
#include <QColor>
#include <QStringRef>
#include <QVector>
#include <QMouseEvent>
#include <zmq.h>
#include "settings/Messages.h"
#include "settings/ParamNames.h"
#include "serialization/TrackedObject.h"
#include "TrackingThread.h"
#include "Exceptions.h"
#include "zmq/ZmqInfoFile.h"
#include "zmq/ZmqClientProcess.h"
namespace BioTracker {
namespace Core {
namespace Zmq {
class ZmqTrackingAlgorithm : public TrackingAlgorithm {
public:
ZmqTrackingAlgorithm(std::shared_ptr<ZmqClientProcess> process, Settings &settings);
virtual ~ZmqTrackingAlgorithm() override;
void track(ulong frameNumber, const cv::Mat &frame) override;
void paint(ProxyMat &, const View &) override;
void paintOverlay(QPainter *, const View &) override;
std::shared_ptr<QWidget> getToolsWidget() override;
// std::set<Qt::Key> &grabbedKeys() const override;
void prepareSave() override;
void postLoad() override;
void postConnect() override;
private:
void mouseMoveEvent(QMouseEvent *) override;
void mousePressEvent(QMouseEvent *) override;
void mouseWheelEvent(QWheelEvent *) override;
void keyPressEvent(QKeyEvent *) override;
void shutdown();
private Q_SLOTS:
void btnClicked(const QString);
void sldValueChanged(const QString, int value);
private:
bool m_isTracking;
std::set<Qt::Key> m_keys;
std::shared_ptr<QWidget> m_tools;
std::shared_ptr<ZmqClientProcess> m_process;
EventHandler m_events;
};
}
}
}