2014-05-21 21:31:42 +00:00
|
|
|
/*
|
|
|
|
|
* ImagesTcpServer.h
|
|
|
|
|
*
|
|
|
|
|
* Created on: 2014-05-21
|
|
|
|
|
* Author: mathieu
|
|
|
|
|
*/
|
|
|
|
|
|
2014-08-02 06:09:27 +00:00
|
|
|
#ifndef IMAGESTCPSERVER_H_
|
|
|
|
|
#define IMAGESTCPSERVER_H_
|
2014-05-21 21:31:42 +00:00
|
|
|
|
2014-07-31 20:11:46 +00:00
|
|
|
#include "find_object/Camera.h"
|
2014-08-02 06:09:27 +00:00
|
|
|
#include <QtNetwork/QTcpSocket>
|
2014-05-21 21:31:42 +00:00
|
|
|
|
2014-08-02 06:09:27 +00:00
|
|
|
class ImagesTcpServer : public QTcpSocket
|
2014-05-21 21:31:42 +00:00
|
|
|
{
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
|
|
public:
|
2014-08-02 06:09:27 +00:00
|
|
|
static QHostAddress getHostAddress();
|
2014-05-21 21:31:42 +00:00
|
|
|
|
2014-08-02 06:09:27 +00:00
|
|
|
public:
|
|
|
|
|
ImagesTcpServer(float hz = 10.0f, const QString & path = "", QObject * parent = 0);
|
2014-05-21 21:31:42 +00:00
|
|
|
|
2014-07-08 19:55:03 +00:00
|
|
|
private Q_SLOTS:
|
2014-08-02 06:09:27 +00:00
|
|
|
void startCamera();
|
2014-05-21 21:31:42 +00:00
|
|
|
void publishImage(const cv::Mat & image);
|
|
|
|
|
|
2014-08-02 06:09:27 +00:00
|
|
|
Q_SIGNALS:
|
|
|
|
|
void connectionLost();
|
|
|
|
|
|
2014-05-21 21:31:42 +00:00
|
|
|
private:
|
|
|
|
|
Camera camera_;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
#endif /* TCPCLIENT_H_ */
|