-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathserver.h
More file actions
44 lines (36 loc) · 753 Bytes
/
Copy pathserver.h
File metadata and controls
44 lines (36 loc) · 753 Bytes
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
#ifndef SERVER_H
#define SERVER_H
#include <QObject>
#include <QtNetwork>
#include <QMutex>
#include <cv.h>
#include <highgui.h>
class Server : public QTcpServer
{
Q_OBJECT
public:
Server();
~Server();
IplImage* frame;
void setFrame(IplImage*);
void setAnalogs(int *);
void setDigitals(int *);
public slots:
void connectionCreated();
void processRead();
void sendFrame(IplImage*);
void sendAnalogs();
void sendDigitals();
private:
int *analogs;
int *digitals;
int pildisuurus; //pildi suurus
int pildisuurus2aste; //pildi suurus kahe astmena
QTcpServer *tcpServer;
QTcpSocket *clientConnection;
QMutex mutex;
void sendData();
CvCapture *cam;
IplImage* img;
};
#endif // SERVER_H