2014-05-21 21:31:42 +00:00
|
|
|
/*
|
|
|
|
|
* ImagesTcpServer.h
|
|
|
|
|
*
|
|
|
|
|
* Created on: 2014-05-21
|
|
|
|
|
* Author: mathieu
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#ifndef TCPCLIENT_H_
|
|
|
|
|
#define TCPCLIENT_H_
|
|
|
|
|
|
|
|
|
|
#include "Camera.h"
|
|
|
|
|
#include <QtNetwork/QTcpServer>
|
|
|
|
|
|
|
|
|
|
class ImagesTcpServer : public QTcpServer
|
|
|
|
|
{
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
|
|
public:
|
2014-07-25 19:31:34 +00:00
|
|
|
ImagesTcpServer(float hz = 10.0f, const QString & path = "", QObject * parent = 0);
|
2014-05-21 21:31:42 +00:00
|
|
|
|
|
|
|
|
QHostAddress getHostAddress() const;
|
|
|
|
|
quint16 getPort() const;
|
|
|
|
|
|
|
|
|
|
|
2014-07-08 19:55:03 +00:00
|
|
|
private Q_SLOTS:
|
2014-05-21 21:31:42 +00:00
|
|
|
void addClient();
|
|
|
|
|
void publishImage(const cv::Mat & image);
|
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
Camera camera_;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
#endif /* TCPCLIENT_H_ */
|