代码拉取完成,页面将自动刷新
#ifndef ONVIFINTERFACE_H
#define ONVIFINTERFACE_H
#include <QDebug>
#include <QObject>
#include "datadictionary.h"
//extern "C" {
//#include "soapH.h"
//#include "soapStub.h"
//#include "wsseapi.h"
//}
#define SOAP_ASSERT(x) do{x;}while(0)
#define SOAP_DBGLOG printf
#define SOAP_DBGERR printf
#define SOAP_TO "urn:schemas-xmlsoap-org:ws:2005:04:discovery"
#define SOAP_ACTION "http://schemas.xmlsoap.org/ws/2005/04/discovery/Probe"
#define SOAP_MCAST_ADDR "soap.udp://239.255.255.250:3702" // onvif规定的组播地址
#define SOAP_ITEM "" // 寻找的设备范围
#define SOAP_TYPES "dn:NetworkVideoTransmitter" // 寻找的设备类型
#define SOAP_SOCK_TIMEOUT (10) // socket超时时间(单秒秒)
#define SOAP_CHECK_ERROR(result, soap, str) \
do { \
if (SOAP_OK != (result) || SOAP_OK != (soap)->error) { \
soap_perror((soap), (str)); \
if (SOAP_OK == (result)) { \
(result) = (soap)->error; \
} \
goto EXIT; \
} \
} while (0)
class OnvifInterface : public QObject
{
Q_OBJECT
public:
OnvifInterface();
int ONVIF_ClientDiscovery(QList<struct CameraInfo> &List);
// struct soap* ONVIF_Initsoap(struct SOAP_ENV__Header *header, const char *was_To, const char *was_Action, int timeout);
private slots:
void CameraCtlDataChange(CameraCtlIndex_t);
private:
// void soap_perror(struct soap *soap, const char *str);
// void* ONVIF_soap_malloc(struct soap *soap, unsigned int n);
// struct soap *ONVIF_soap_new(int timeout);
// void ONVIF_soap_delete(struct soap *soap);
// void ONVIF_init_header(struct soap *soap);
// void ONVIF_init_ProbeType(struct soap *soap, struct wsdd__ProbeType *probe);
void ONVIF_DetectDevice(QList<CameraInfo_t> &List);
int ONVIF_GetDeviceInformation(const char *DeviceXAddr);
// int ONVIF_GetDpAddr(const char *DeviceXAddr, const char *UsrName, const char *Pw, QList<CameraNetworkInfo_t> &list);
int ONVIF_GetDNS(const char *DeviceXAddr,const char *UsrName,const char *Pw,QList<CameraNetworkInfo_t> &list);
int ONVIF_SetDNS(const char *DeviceXAddr, const char *UsrName, const char *Pw, QList<CameraNetworkInfo_t> &list);
int ONVIF_GetNTP(const char *DeviceXAddr,const char *UsrName,const char *Pw,QList<CameraNetworkInfo_t> &list);
int ONVIF_GetGateway(const char *DeviceXAddr,const char *UsrName,const char *Pw,QList<CameraNetworkInfo_t> &list);
int ONVIF_SetGateway(const char *DeviceXAddr, const char *UsrName, const char *Pw, QList<CameraNetworkInfo_t> &list);
int ONVIF_GetNetworkInterfaces(const char *DeviceXAddr, const char *UsrName, const char *Pw, QList<CameraNetworkInfo_t> &list);
int ONVIF_SetNetworkInterfaces(const char *DeviceXAddr,const char *UsrName,const char *Pw,QList<CameraNetworkInfo_t> &list);
int ONVIF_GetZeroConfiguration(const char *DeviceXAddr,const char *UsrName,const char *Pw,QList<CameraNetworkInfo_t> &list);
int ONVIF_GetVideoSourceConfigurations(const char *DeviceXAddr,const char *UsrName,const char *Pw,QList<CameraConfigInfo_t> &list);
int ONVIF_GetVideoEncoderConfigurations(const char *DeviceXAddr, const char *UsrName, const char *Pw, QList<CameraConfigInfo_t> &list);
int ONVIF_SetVideoEncoderConfigurations(const char *DeviceXAddr,const char *UsrName,const char *Pw,QList<CameraConfigInfo_t> &list);
int ONVIF_SystemReboot(const char *DeviceXAddr,const char *UsrName,const char *Pw);
private:
DataDictionary *m_DataDictionary;
};
#endif // ONVIFINTERFACE_H
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。