-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathdisplaydata.h
More file actions
86 lines (65 loc) · 2.01 KB
/
Copy pathdisplaydata.h
File metadata and controls
86 lines (65 loc) · 2.01 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
81
82
83
84
85
86
#ifndef DISPLAYDATA_H
#define DISPLAYDATA_H
#include <QScrollBar>
#include "dialogconfig.h"
#include "visimage.h"
namespace Ui {class DisplayData;}
class DisplayData : public QMainWindow{
Q_OBJECT
public:
explicit DisplayData(QWidget *parent = nullptr);
~DisplayData();
int selfCount = -1;
VersionID* versID = nullptr;
bool isMirrored = false;
// --- conf window ---
DialogConfig* dConfig = nullptr;
void receiveCanLine(const CanLine &canLine);
private slots:
void slotRadNum(int index);
void slotInfo(bool checked);
void slotConfigRadarCall();
void slotUpdateWarningsUI();
// --- visual ---
void slotZoomChanged(int val);
void slotSAHorizChanged(int val);
void slotSAVertChanged(int val);
void slotPathReset(){radarPathCm = 0;}
signals:
void signRadarWarningsUI();
void signUpdRegionList();
private:
Ui::DisplayData *ui;
VisImage *vDraw = nullptr;
const float aspect = 0.46f;
QPointF saCentr = QPointF(0.5f, 0);
uint8_t countStartResize = 0;
void resizeEvent(QResizeEvent *event) override;
// --- clusters ---
ClusterList clustList;
std::vector<ClusterInfo> clustersAll;
std::vector<ClusterInfo> clustersFiltered;
// --- objects ---
ObjectList objList;
std::vector<ObjectInfo> objectsAll;
std::vector<ObjectInfo> objectsFiltered;
void applyFilters();
void updateShowFlags();
// --- SPPED ---
std::array<uint8_t, DATA_SIZE> histoVLong;
std::array<ClusterInfo, DATA_SIZE> m_dataInfo;
StatusSpeed statusSpeed = StatusSpeed::slowSpeed;
float averSpeedKalman = 0.0f;
float averQuality = 0.0f;
float speedVehicle = 0.0f;
float speedQuality = 0.0f;
float koeffKalmanSpeed = 1.0f; // 0.1...1.0 smooth...sharp
float koeffKalmanQuality = 0.2f;
int16_t zonaAnalyseQuality = 10;
int32_t radarPathCm = 0; // cm
uint64_t lastRadar600Ms = 0;
int calcSpeed();
void calcPath();
void showSpeedPathUI();
};
#endif // DISPLAYDATA_H