You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

87 lines
1.6 KiB
C++

#ifndef _HVDLLSTRH_
#define _HVDLLSTRH_
#include "GeneralModule.h"
#include "libHvDevice/HvDeviceEx.h"
class HvdllStr
{
public:
HvdllStr();
~HvdllStr();
private:
int InitStr();
void InitCallBackStr(myFunCallBack & callstr);
void CreatePlateNo(char * plateno, char * pColor, int isNoPlate =0);
void CreateImgSize(WORD &whigh, WORD &wlow, DWORD dLen);
//回调函数响应
public:
int OnRecordInfoBegin(DWORD dwCarID);
int OnRecordInfoEnd(DWORD dwCarID);
int OnRecordInfoPlate(
DWORD dwCarID,
LPCSTR pcPlateNo,
LPCSTR pcAppendInfo,
DWORD dwRecordType,
DWORD64 dw64TimeMS);
int OnRecordInfoBigImage(
DWORD dwCarID,
WORD wImgType,
WORD wWidth,
WORD wHeight,
PBYTE pbPicData,
DWORD dwImgDataLen,
DWORD dwRecordType,
DWORD64 dw64TimeMS);
int OnRecordInfoSmallImage(
DWORD dwCarID,
WORD wWidth,
WORD wHeight,
PBYTE pbPicData,
DWORD dwImgDataLen,
DWORD dwRecordType,
DWORD64 dw64TimeMS);
int OnRecordInfoBinaryImage(
DWORD dwCarID,
WORD wWidth,
WORD wHeight,
PBYTE pbPicData,
DWORD dwImgDataLen,
DWORD dwRecordType,
DWORD64 dw64TimeMS);
public:
int OpenHv(char * pcIP);
HRESULT CloseHv();
HRESULT HvIsConnected(INT32 *piStatus);
HRESULT SetHvCallBack(
void *pFunction,
void *pFirstParameter,
WORD wVideoID,
WORD wStream
);
private:
HVAPI_HANDLE_EX m_hDevice;
char m_ipAddr[32];
char m_PlateNoBuf[64];
myFunCallBack m_BeginFunStr;
myFunCallBack m_EndFunStr;
myFunCallBack m_PlateFunStr;
myFunCallBack m_BiglmgFunStr;
myFunCallBack m_SmallImgFunStr;
myFunCallBack m_BinaryImgFunStr;
};
#endif