-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompresswindow.h
More file actions
64 lines (50 loc) · 1.27 KB
/
Copy pathcompresswindow.h
File metadata and controls
64 lines (50 loc) · 1.27 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
#ifndef COMPRESSWINDOW_H
#define COMPRESSWINDOW_H
#include <QMainWindow>
#include<QMenuBar>
#include<QMenu>
#include<QAction>
#include<QFileDialog>
#include<QMessageBox>
#include<QString>
#include<QTextEdit>
#include<QFile>
#include<QTextStream>
#include<QFileDialog>
#include <QAbstractButton>
#include "Compress_gray.h"
namespace Ui {
class CompressWindow;
}
class CompressWindow : public QMainWindow
{
Q_OBJECT
public:
explicit CompressWindow(QWidget *parent = nullptr);
virtual void resizeEvent(QResizeEvent* event);/*选择图片的槽函数声明*/
~CompressWindow();
signals:
void returnmain();/*发出回到主界面的信号*/
void touncompress();/*发出去解压缩界面的信号*/
void tohelp();/*发出回到帮助界面的信号*/
private slots:
void on_runbtn_clicked();
void on_savebtn_clicked();
void on_colorfulphoto_clicked();
void on_blackphoto_clicked();
void on_choosebtn_clicked();
void on_uncompressBtn_clicked();
private:
Ui::CompressWindow *ui;
QImage m_imgSrc;
QImage m_img2show;
QPixmap m_pix2show;
QString strFileName;
QString savePath;
Compress_gray* cg;
//允许误差
double sigma = 10;
//彩色1 灰度0
int isColorful = 0;
};
#endif // COMPRESSWINDOW_H