-
Notifications
You must be signed in to change notification settings - Fork 0
/
maindisplay.h
109 lines (67 loc) · 1.99 KB
/
maindisplay.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
#ifndef MAINDISPLAY_H
#define MAINDISPLAY_H
#include <QObject>
#include <QWidget>
#include <QPainter>
#include <stdio.h>
#include <QTimer>
#include <QDateTime>
#include <QDesktopWidget>
#include "headerctrl.h"
extern QRect timeRect,dateRect,freqRect,eleRect,dfreqRatioRect,distanceRect;//save rect of time,date,frequency,elevation
class MainDisplay : public QWidget
{
Q_OBJECT
public:
explicit MainDisplay(QWidget *parent = 0);
~MainDisplay();
signals:
public slots:
void on_update_timeout();
public:
unsigned char PalColorMat[palColorNum][baseColorNum]; //调色板颜色矩阵256*3
//色标
Palette dBZPal[palNum],dBTPal[palNum],vPal[palNum],wPal[palNum];
//扇形
Sector dBZSector,dBTSector,vSector,wSector;
int colorNums;
bool isPalExist;
QPainter painter;
void paintEvent(QPaintEvent *);
//绘制调色板V,W,DBT,DBZ
void paintShadeGuide();
void paintVPal(Palette pal[],int palLenth,QPoint slt);
void paintWPal(Palette pal[],int palLenth,QPoint slt);
void paintDBTPal(Palette pal[],int palLenth,QPoint slt);
void paintDBZPal(Palette pal[],int palLenth,QPoint slt);
/*生成颜色库 R,G,B,RG,GB,RB,RGB*/
int colorBinFactory();
/*绘制调色板*/
int paintPal(Palette pal);
/*绘制扇形*/
int paintSector(Sector *pSector);
/*控制扇形的绘制*/
int paintManager();
/*绘制数据点*/
int startPaint(unsigned char *pbuff,Sector *pSector);
int paintDBZ( );
int paintDBT( );
int paintV( );
int paintW( );
/*paint picture title*/
int paintTitle(QRect rect,const char*p);
//
void paintDispInfo();
int paint4PicMode() ;
int paint2PicZTMode ();
int paint2PicZVMode( );
int paint2PicZWMode ();
int paint2PicTVMode ();
int paint2PicTWMode ();
int paint2PicVWMode ();
int paint1PicZMode ();
int paint1PicTMode ();
int paint1PicVMode ();
int paint1PicWMode ();
};
#endif // MAINDISPLAY_H