-
Notifications
You must be signed in to change notification settings - Fork 0
/
iscissor.h
executable file
·77 lines (54 loc) · 1.39 KB
/
iscissor.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
#ifndef iScissor_H
#define iScissor_H
#include <iostream>
#include <QMainWindow>
#include <QLabel>
#include <QProcess>
#include <QString>
#include <QScrollBar>
#include <QFileDialog>
#include <QMessageBox>
#include "ImgLabel.h"
#include "LiveWireDP.h"
namespace Ui {
class iScissor;
}
class iScissor : public QMainWindow
{
Q_OBJECT
public:
QImage original_img;
QImage edge_img;
int img_height;
int img_width;
int mouse_curr_pos_x;
int mouse_curr_pos_y;
int seed_x;
int seed_y;
LiveWireDP my_LiveWireDP;
std::vector<weight_t> min_distance;
std::vector<vertex_t> prev_vertex;
explicit iScissor(QWidget *parent = 0);
~iScissor();
public slots:
private slots:
void on_actionOpen_triggered();
void on_actionSaveMask_triggered();
void on_actionSaveContour_triggered();
void on_actionZoom_in_triggered();
void on_actionZoom_Out_triggered();
void on_actionScissorStart_triggered();
void on_actionScissorStop_triggered();
void on_actionScissorUndoLast_triggered();
private:
Ui::iScissor *ui;
bool image_loaded;
bool seed_changed;
//Scaling
void scaleImage(double factor);
void adjustScrollBar(QScrollBar *scrollBar, double factor);
double scaleFactor;
signals:
void scale_changed(double);
};
#endif // iScissor_H