-
Notifications
You must be signed in to change notification settings - Fork 1
/
HaikangCam.h
58 lines (39 loc) · 1.02 KB
/
HaikangCam.h
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#ifndef _HAIKANGCAM_H_
#define _HAIKANGCAM_H_
#include "MvCameraControl.h"
#define HK_OK 0
#define HK_FAIL -1
class HaikangCam
{
public:
HaikangCam();
~HaikangCam();
// 枚举设备
int EnumDevices();
// 打开设备
int Open(int i);
// 关闭设备
int Close();
// 开启抓图
int StartGrabbing();
// 停止抓图
int StopGrabbing();
// 注册图像数据回调
int RegisterImageCallBack(void(__stdcall* cbOutput)(unsigned char * pData, MV_FRAME_OUT_INFO_EX* pFrameInfo, void* pUser), void* pUser);
// 设置AOI
int SetAOI(const unsigned int offsetX, const unsigned int Width, const unsigned int offsetY, const unsigned int Height);
// 设置帧率
int SetFrame(const unsigned int framerate);
// 设置自动曝光
int SetExposure(const unsigned int TimeLower, const unsigned int TimeUpper);
// 关闭触发
int CloseTrigger();
// 设置连续模式
int SetAcquisitionMode();
private:
void* m_hDevHandle;
MV_CC_DEVICE_INFO_LIST pstDevList;
public:
float hk_frame;
};
#endif